score:116

Accepted answer

did you try to un-select

window > preferences > java > debug : suspend execution on uncaught exceptions

? (as mentioned in this thread, for instance)

alt text

why does eclipse work that way?

it goes back to 2002, when the breakpoint object hierarchy has been stripped down.

in order to set a breakpoint, with the old api, a client required java model objects - such as itype, ifield, etc.
with the new api, all that is required by the debug model is type names, field names, etc.

this allows clients to set breakpoints when java model objects are not available.
clients now specify the resource to associate a breakpoint with (before we constrained it to the associated java model resources).

breakpoints can now also be "hidden". that is, they need not be registered with the breakpoint manager.
breakpoints can also be selectively persisted (markers only allowed all/none of a marker type to be persisted).
this makes the debug model more flexible, and gives clients more building blocks.

this has also simplified some part of our java debug implementation - for example, the feature "suspend on any uncaught exception", simply sets a breakpoint for the type named "java.lang.throwable", rather than a specific itype in a specific project.
the breakpoint is not registered with the breakpoint manager (i.e. hidden) - it is only known and used by one client.
another example is the "run to line breakpoint". the ijavaruntolinebreakpoint has been removed, as its special functionality is no longer required. now, the java debug ui simply creates a "line breakpoint" that is hidden, non persisted, and has a hit count of 1. this is an example of providing building blocks to clients.

score:0

for those who didn't find a solution from the previous answers, they can try what solved my problem. it is i think similar to hal9000 problem/solution

if you have two classes with the same name (in two different projects) the breakpoints on the one, apply on the other one as well. both of them show in the "breakpoints" window.

solution: if you remove the breakpoint from the class - with the same name - that you are not using it removes the breakpoint from the class you are debugging.

score:3

i ran into an issue where a source file had persistent markers for breakpoints that didn't exist. i tried cleaning the project, doing a full build, restarting eclipse - nothing worked.

i went digging through the eclipse metadata, and found the projects .markers file. deleting that file finally fixed the issue.

for anyone else having this issue, open your workspace directory, then navigate to .metadata/.plugins/org.eclipse.core.resources/.projects/your project, then rename/remove file .markers.

for example, if your workspace folder is ~/workspace, and your project is named foo, you could do:

$ mv ~/workspace/.metadata/.plugins/org.eclipse.core.resources/.projects/foo/.markers ~/safe.foo.markers

score:5

for those who don't find other solutions useful, i found my personal solution to my problem. i work with a .jar library which is generated by building another project into the workspace. if i set a breakpoint in a .java into the library project, then the breakpoint will be triggered when debugging the final project. however when debugger pauses the execution the .class file is shown which has its own breakpoints and therefore the breakpoint set into the .java file is not shown here!

solution: in order to remove the breakpoint you have to remove the breakpoint into the .java file, in the library project.

score:40

i had a similar problem but the accepted solution did not work for me. i am doing eclipse android development and had set some breakpoints and later unset them. even though i disabled them eclipse kept stopping execution at these phantom breakpoints. the solution for me was to open the breakpoints window:

window > show view > other...

debug > breakpoints

then right click any breakpoint and select "remove all"

unfortunately you have to reset all your valid breakpoints, but this worked for me and has prevented much angst and frustration going forward.

some pictures to guide others:

add breakpoints window to eclipse

remove all (breakpoints, right click)


Related Query

More Query from same tag