I'm android developer and I use Eclipse.
Sometimes, when I am debugging my apps, Eclipse doesn't stop on my breakpoints. Eclipse shows a "v" symbol on the breakpoint. I think this symbol means that Eclipse has passed the breakpoint without problems, but I would like Eclipse to stop when it reaches the breakpoint.
Of course, I have pressed the debug button (the icon with the green bug on it.)
How can I avoid this behavior?
Most likley your source and class files run out of sync. If this happens clean and rebuild your project. This should make the issue disappear.
solved, it's because i have that activity in another process in the manifest... wow
Old post - but pulled my hair out for a few hours with intermittent trace/breakpoints, so this may help someone.
The solution for me was simply to use the --clean flag to start Eclipse, so ./eclipse --clean
Related
So I've been working on projects for my class and I had a small error in an extra instance I was calling. I hit clean to see if it would clear it out and instead it created errors on all of my buttons and all of my toasts. It now says they all cannot be resolved or are not fields. They were all working fine until I had hit clean as I had tested everything right before doing so. Has anyone else had this occur?
I know it sounds weird, but this occurs when there is an error in one of the .XML layouts, no matter Eclipse is not detecting it. Please check any recent changes in XMLs and clean again.
Every time I open an activity layout in order to view its design, I can't see anything, and there's a "Loading configuration" message. How to solve it?
Looks like this is related to the following issue: https://code.google.com/p/android/issues/detail?id=56691&q=%22Loading%20Configuration%22&colspec=ID%20Type%20Status%20Owner%20Summary%20Stars
I had the same issue and it got solved by using the menu item: File->Invalidate Caches/Restart
Try to delete the build folder.
Here are the details:
Yesterday(2015/6/10) I faced to the same problem, and I solved it by using beyond compare:
This problem occured after a forced upgrade.
I have 2 projects, one worked(newly created) and one doesn't.
So I used beyond compare to compare the 2 projects' folders.
Luckily I found build folder of the not-worked never changed even though I clear cache, restart and rebuild it several times.
build folder deleted and everything worked fine now.
I've had this issue before, and it was usually not long after an error had come up.
Check the Event Log for errors. Usually a restart of the IDE fixed it for me though I appreciate that's not ideal. The errors weren't anything specific I think just teething issues with Android Studio - tis just preview software after all.
I ran my program just fine a few minutes ago, and when I added more functionality now it is telling me "The JRE Instance Default XSLT processor does not support debugging_ Would you like to debug using the default Xalan 2.7.1 processor instead?"
I did restart Eclipse maybe that has something to do with it? :/
It's my first times writing an app so if I have to set something in eclipse each time maybe that's why? and what is it if that is the case.
Thanks!
You were in an XML file when you hit debug, I would bet. Happens to me all the time. For some annoying reason it does something entirely different that I don't understand when you do that. Delete the .out.xml that should probably have been created, open a .java file, and try to debug again. Another way is to just right-click your project and do Run As > Android Application.
I'm having a troubling problem testing some code for and Android app. My app has two parts, and activity where the user changes some settings, and a broadcast receiver that responds to SMS messages, both in the same package.
Here's the problem, I first implemented some simple code to test out the broadcast receiver and the activity, and both worked fine. But then as I tried to refine the code, I noticed the emulator wasn't picking up any of my changes. Event went so far as to uninstall the app from the emulator and try again, no luck. Then I added some extra Toast popups to my receiver, nothing, still running the old code. I know its running the old code because its sending out an SMS using a string constant that is no longer in the current code, so it should be impossible that it respond with that value.
Here's the kicker that has me confused. For fun I made a change to my activity. Ran the project from Eclipse and that change showed up! Tried to test the receiver code again, runs the old code that doesn't even exist anymore!!
How in the world can half the package update, and the other half not?
Can anyone help me out 'cause I'm about ready to lose my mind.
I had a similar problem. Changes made to classes imported from another project didn't get picked up by eclipse, but those made to classes in the current android project were.
Making a change to the current android project (inserting a blank line and deleting it) seemed to make eclipse pick up all the changes made and upload the app to the emulator.
I had this problem too, Now I found a working solution. Just follow these steps:
Run your project normally.
When emulator started, run your project again (DO NOT close the first emulator)
Then the updated application will be uploaded into emulator
I can't really be sure what happened but creating an new emulator image appeared to solve the issue.
I don't know why it happens but it's a problem I have all the time.
What I typically do is
Close the emulator
Close Eclipse
Reopen Eclipse
Clean the projects (in Eclipse, select Project -> Clean... -> Clean all projects)
Rerun the emulator
Annoying as hell but seems to work for me.
I'm having this problem too. It mostly happens when errors are entered into the code. The strange thing is if I go back to the original code, Eclipse doesn't revert to the original code. One thing that seems to help is to temporary delete the contents of a file, save, and rebuild, and then enter the contents back into the file, save, and rebuild.
How is one supposed to debug in such an environment?
When I run my app on my phone from eclipse, it always runs in debug. This has only recently started to happen. I guess I must have inadvertently changed a preference or something, but can't work out what. Does anyone know how I can switch it back so I can run without debugging?
Thanks in advance
TAO
I found someone else reporting the same error
http://osdir.com/ml/AndroidDevelopers/2009-08/msg00603.html
They resolved it with a phone restart.
The same worked for me.... how frustrating!!!!!!
At least its working now.
Massive thanks Aaron Digulla for our help.
TAO
Check the VM options in the project's properties. There should be something like -Xdebug=.... Remove that.
I suggest to duplicate the entry and create a second one without the debug options. Also note that under Common, you can save the launch config somewhere (for example in your project), so this setup doesn't get lost.
Just ran across this issue.
Sometimes the Eclipse Android dev environment sets the application property android:debuggable="true" in the AndroidManifest.xml file. This will cause your app to run in debug mode regardless of if you press 'run' or 'debug' in Eclipse.
I know this contribution comes a little late, but here it goes. Be sure you do not have any android.os.Debug.waitForDebugger() method invoked since your code. If so, just remove or comment it and rerun your application.