Everytime I start the emulator from eclipse, I get the following error in my console.
[2010-09-13 17:04:51 - DeviceMonitor]Sending jdwp tracking request failed!
[2010-09-13 17:18:49 - DeviceMonitor]Sending jdwp tracking request failed!
The application works fine, but I am concerned as to why I see this error. Please help
I believe this is coming from the Usage Stats option. I just installed ADT, did a test run and got this error, as well. I went to Window >> Preferences >> Android >> Usage Stats then checked it on. Tried another test and voila! No error!
Kind of annoying, I can imagine...
This is caused after the emulator is closed while eclipse is still running.
When you first run the emulator after starting eclipse, a connection is established between it and eclipse. This connection is used to send messages back and forth between the two programs, and so eclipse can track the progress of the emulator.
When the emulator is closed, the connection is lost, and any attempt by eclipse to send a message results in the error messages you describe.
As Koby said this message comes if you close the emulator after running an application. First of all between successive application running on emulator you don't need to close the emulator. First before running the application you start the emulator by clicking window-->Android SDK and AVD Manager and click on the emulator you want to launch and click on 'start' button and then click on 'Launch' to launch the emulator. After the emulator launches unlock the emulator and keep that emulator minimized. And if you want to run an application go for 'run as android app' and you can see that on the emulator when maximized. After running that application if you want to make some changes in the application you don't need to close the emulator. you press the home button after running the application and keep the emulator minimized. Make the changes on the code and again go for running the application. Thus you can avoid that error message and save time for launching the emulator. if you got that error message then also the application will work properly but you cannot see the messages like uploading app-->installing .apk-->and the success messages. But these will be happening on the background. One way to overcome this is to restart the eclipse.
Related
Today, I update my Android Studio(4.1.1)
When I changes in my code and click on "Run App" then dialog shows Do you want to terminate the process 'app' and there are 3 options Terminate, Disconnect, Cancel.
Can you tell me what are difference in these because if click anyone then app restart.
Which option is best?
There is best option. What you have to select depends on what you want to achieve.
This dialog only makes sense if you have already started the app before. If you now run again the app Android Studio want's to know what to do with the existing running app as an there can be only one running instance of an app at a time.
Terminate
This will directly exit the app without saving and data or anything else.
The app process will just be terminated.
Disconnect
Close the connection between the debugger in Android Studio and the app as the debuggee.
Afterwards the app will continue to run just without attached debugger.
Cancel
Do nothing and just close the dialog
Command , (Setting or Preference)
Version Controll > Confirmation > "when files are created"
add or delete option check!!
I was having the same problem. Here is the simple solution that worked for me. Check Remember, don't ask again then press Disconnects. Lastly close your emulator and run the app again.
After running the command expo start --android , I received an error message of request time out. Upon clicking on Retry, this screen appeared and my application never gets launched:
How can I get rid of it and what can be the root cause of this?
solved: I relaunched my application on an another emulator.
As I wanted to debug my app, I clicked the Debug button. After this, if I was trying to run the app manually, a message appeared saying "Waiting for debugger to attach...". I turned off and turned on the "Debuggable app" option in the Developer settings and rebooted my phone and this dialog disappeared.
But now when I'm trying to click the Run button in Android Studio, the app doesn't run, but lines of log are running at the ADB window (Android monitor). Feels like it's running in the background.
The only way to launch my app and track it is to click the Debug button, set the Breakpoint, run the app manually, click the Debug button again. But I don't want to Debug!
P.S. Sorry for that bad English.
Stop the debugging process and rebuild your project. It works for me. Try it.
My app is no longer starting up automatically when I F11 it in Eclipse; the Emulator starts up, but I then have to go and find my app among the applications list/array to invoke it.
Then, when I get to the place in my app where I've set a breakpoint, instead of hitting the breakpoint (Eclipse is not even going into Debug Perspective), my app suddenly "expires" and the Emulator pops up the dialog:
~~~~~~~~~~~~~~~~~~~~~~~~~
Sorry!
The application FifeOrTheDinosaur (process.com.aXX3AndSpace.FifeOrTheDinosaur_Package) has stopped unexpectedly. Please try again.
Force close
~~~~~~~~~~~~~~~~~~~~~~~~~
But then when I click "Force Close," that dialog goes away, and my app starts up again, from its opening Activity...?!?
It's almost as if my app is not the one being debugged by Eclipse -- Eclipse has lost its connection to it or...???
And every time it crashed, I hit the "Force Close" button, whereupon my app starts up all over again. What could have disconnected my app from the Debugging system, so that it:
1) Doesn't run automatically when I run it; rather, I have to "force" it to start up, and when it enters a breakpoint, Eclipse's Debug Perspective is not invoked
2) Continually starts up my app after it has failed...???
I put a breakpoint on a button click handler prior to that one that is working fine, and it does not drop me into the Eclipse debugger, either...???
Update:
The console says:
1) ] Failed to install .apk on device 'emulator-5554': timeout
2) Launch canceled!
Updated 3/30/2012:
If I run the app from Eclipse and immediately shut it down just as the Emulator is starting to initialize, it flashes up three "command window"-type screens, one right after the other, too fast to read what text they contain. Normally the Emulator window simply goes away, so I don't know if this is a clue for anybody as to what might be happening...
That sounds like the normal behavior of android Apps. If one activity crashes you can still go back to the activity the App started with. And if the breakpoints aren't hit then the error might occure before the code line you want to stop at.
Maybe you could set a breakpoint before you change the activity and then debug from there on.
You could also provide your Log output. Errors like that can always happen if you forgot to declare permissions or activities in your Android Manifest.
I have developed and android application which is called after phone boot is completed. Now, for testing it I am using my android phone and every time I have to switch on and off my phone to test it.
Is there any command on for android emulator which switch offs and switch on it. I want to test it on android emulator. Let me know how can I do it.
I wrote such a boot service. Just close the emulator window, and reopen it to test the boot service.
But it's tricky: When you start the emulator window again, be carefull not to use the run button. If you use the run button, the application will be installed again, and the boot service is not active right after installation.
So you need to install the application, close the emulator, and then to open the emulator using the green button in the toolbar. If you can't find this button, just start any other Android project.
Your boot service will now be executed.