im using eclipse to develop android app.
Im debugging my app on real device, htc desire hd.
When i start my app from eclipse its allways restart my phone.
This behavior wasnt allways like this and suddenly happaned.
I tried 3 different ROMs all 4.2.2 and its happing in all of them.
In my log cat i dont see any errors except this in my console:
[2013-09-05 21:25:33 - WorkoutLog2] Failed to install WorkoutLog2.apk on device 'HT0BRRX047774!
[2013-09-05 21:25:33 - WorkoutLog2] (null)
[2013-09-05 21:25:33 - WorkoutLog2] Launch failed on device: HT0BRRX047774
Why this is happening?
Related
Since updating my iPad to iOS 15, I can no longer run the debug version of my app on it (the prod version works fine). It gives me an error saying "The developer of this app needs to update it to work with this version of iPadOS."
Googling this error, I found a post about going to 64 bit by default to resolve this, back from 2017 (https://www.codenameone.com/blog/moving-to-64bit-by-default.html)
I checked my app settings and I don't have the hint that would force a 32bit build (ios.debug.archs=armv7). Is there anything else I can check to see why this is happening?
This is probably related to this: https://www.reddit.com/r/cn1/comments/ori4ve/ios_14_support/
Try the ios.zsign=true build hint.
We have a desktop JavaFX application (well, TornadoFX) that downloads an archive, extracts another app from it and launches this app with macOS open command.
Simplified kotlin code looks like:
ProcessBuilder(listOf("open", "/path/to/app.app", "arg")).start()
This has worked for years on older versions of macOS (10.15 and earlier) but now with macOS 11 Big Sur launching the app sometimes succeeds and sometimes fails.
In the mac Console.app following error can be seen:
OSStatus _LSCopyApplicationNodeFromOpenState(LSOpenState *): Returning kLSNoExecutableErr because node is a directory but we failed to register with error -10814
We extended the logic to check if all the files are really there before launching the app, and the files existed.
There is an assumption that maybe Launch Services database is not updated fast enough.
Following ways of trying to log what might be happening, didn't reveal any errors:
lsappinfo listen +all forever
log stream --debug --predicate 'subsystem == "com.apple.coreservices.launchservices"'
Does anybody have a clue if there is a way to avoid this behavior and to be always able to launch the app?
After a lot of research and debugging, what seem to have worked for us, was to force Launch Services to register the app in its database by executing command like:
/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -f /path/to/app.app
and afterwards we could launch the app.
The idea for such solution was found in this answer.
When I change the code and try to lauch the app sometimes this happends:
Installing ...
Success
Launching application: ...
DEVICE SHELL COMMAND: ...
java.lang.UnsatisfiedLinkError: No implementation found for java.lang.String android.os.SystemProperties.native_get(java.lang.String) (tried Java_android_os_SystemProperties_native_1get and Java_android_os_SystemProperties_native_1get__Ljava_lang_String_2)
at android.os.SystemProperties.native_get(Native Method)
at android.os.SystemProperties.get(SystemProperties.java:52)
at com.htc.customization.HtcCustomizationManager.<init>(HtcCustomizationManager.java:65)
at com.htc.customization.HtcCustomizationManager.<clinit>(HtcCustomizationManager.java:60)
at android.os.Environment$UserEnvironment.getCustomizationReader(Environment.java:523)
at android.os.Environment$UserEnvironment.isDynamicSwitchSupported(Environment.java:534)
at android.os.Environment$UserEnvironment.<init>(Environment.java:222)
at android.os.Environment.initForCurrentUser(Environment.java:142)
at android.os.Environment.<clinit>(Environment.java:136)
at android.os.Environment.getLegacyExternalStorageDirectory(Environment.java:726)
at android.os.Debug.<clinit>(Debug.java:96)
at android.ddm.DdmHandleHello.handleHELO(DdmHandleHello.java:164)
at android.ddm.DdmHandleHello.handleChunk(DdmHandleHello.java:91)
at org.apache.harmony.dalvik.ddmc.DdmServer.dispatch(DdmServer.java:171)
java.lang.UnsatisfiedLinkError: android.os.Debug
at android.ddm.DdmHandleHello.handleFEAT(DdmHandleHello.java:176)
at android.ddm.DdmHandleHello.handleChunk(DdmHandleHello.java:93)
at org.apache.harmony.dalvik.ddmc.DdmServer.dispatch(DdmServer.java:171)
java.lang.UnsatisfiedLinkError: android.os.Debug
at android.ddm.DdmHandleProfiling.handleMPRQ(DdmHandleProfiling.java:215)
at android.ddm.DdmHandleProfiling.handleChunk(DdmHandleProfiling.java:106)
at org.apache.harmony.dalvik.ddmc.DdmServer.dispatch(DdmServer.java:171)
Aborted
And the app does not lauch unless I rebuild the solution - then it launches fine
This is not that serious but very annoying as it happens once every 3-4 builds
What is wrong?
You probably have and HTC phone (M8 I'd guess) with HTC Sense. There is a bug in their code which prevents you from installing the app sometimes. Here's relevant question and answer from HTCdev FAQ:
Why does my debug APK sometimes fail to install or run on my device
and how to recover?
HTC devices with Lollipop 5.0.0 or 5.0.1 may experience this issue and
we suggest retrying the installation step for workaround. HTC will
prepare the solution to address the issue on Lollipop MR1.
So, nothing you can do but to wait for Android update. Since HTC backed off from pushing Lollipop MR1, you will have to wait for Marshmallow update.
I'm trying to parse an XML file thru a DOM parser. However, I am having difficulty in getting my Main Activity to actually read the file. I've read that I should place the file in Assets and then called with getAssets(). I used something like this:
InputStream is = this.getAssets().open("myXML.xml");
This just results in an error: Unexpected error while launching logcat. Try reselecting the device.] device not found.
I've also tried new File("myXML.xml") using variations on the absolute path. Nothing seems to work. I'm getting a little frustrated. Does anyone have any suggestions?
sounds to me, as if your IDE has no connection to the Emulator or device on which you are trying to test your app.
LogCat is a logging output stream that can be used by any app to print out informations /logs. And LogCat needs to be connected (via ADB) to your device.
If you don't have a real phone connected you can use an emulator:
/path/to/your/androidSDK/tools/android
this SDK manager helps you to create a new AVD (Android Virtual Device). Klick Tools>
Manage ACDs> New...
If you have a real phone or tablet connected to your computer, try restarting ADB
(should be possible from within your IDE) or use the command line.
change to the directory where the Android SDK is installed (in windows something like):
c:\Program Files\Android\android-sdk-windows\platform-tools\
on linux it could be:
/opt/android-sdk-linux/platform-tools/
then type (win and linux)
adb kill-server
adb start-server
I am trying to run Apidemos sample on my PC.
for that fst i hav launched AVD nd then run tht Apidemos app..
but it is giving me following errors...
[2010-10-16 10:33:43 - ApiDemos] Performing com.example.android.apis.ApiDemos activity launch
[2010-10-16 10:33:44 - ApiDemos] Automatic Target Mode: using existing emulator 'emulator-5554' running compatible AVD 'apidemoavd'
[2010-10-16 10:33:44 - ApiDemos] **WARNING: Application does not specify an API level requirement!**
[2010-10-16 10:33:44 - ApiDemos] **Device API version is 7 (Android 2.1-update1)**
[2010-10-16 10:33:44 - ApiDemos] Uploading ApiDemos.apk onto device 'emulator-5554'
[2010-10-16 10:33:52 - ApiDemos] **Failed to upload ApiDemos.apk on device 'emulator-5554'**
[2010-10-16 10:33:52 - ApiDemos] **java.io.IOException: Unable to open sync connection!
[2010-10-16 10:33:52 - ApiDemos] Launch canceled!**
To fix the API level warning, check uses-sdk element.
The failure seems to be caused by a disconnected device. Remember that you should allow USB debugging.
Try the steps recommended in the documentation: Eclipse isn't talking to the emulator
Let us know if that works. There are several more things that can be done if that doesn't work.
Please:
Open the SDK manager
Then download the latest APIs and API Tools from here
Then you need to start new AVD using one of the downloaded APIs