This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 144098

Summary: By default create excetion breakpoints for well-known exception
Product: debugger Reporter: Jaroslav Tulach <jtulach>
Component: JavaAssignee: issues@debugger <issues>
Status: RESOLVED WONTFIX    
Severity: blocker CC: dkonecny, fzamboj, locked
Priority: P3    
Version: 6.x   
Hardware: All   
OS: All   
Issue Type: ENHANCEMENT Exception Reporter:

Description Jaroslav Tulach 2008-08-15 16:33:12 UTC
By an accident I have created an exception breakpoint for NullPointerException, AssertionError, AssertionFailedError 
exceptions and forgot about that. However whenever I debuged my application, it suddenly stopped whenever there was an 
error in my code. For a while I could not understand why, but then I got it! An error usually means, an exception is 
raised, and I had my exception breakpoints enabled. I started to like this setup as instead of getting NPE error, the 
application stopped and I could inspect the values before the exception is thrown and the application continues.

This leads me to my suggestion: By default the debugger shall have some exception breakpoints, for well known 
exceptions enabled.

Of course this needs a bit more logic. Very likely I do not care about catched NullPointerExceptions in JDK, etc. But 
I know there is already filtering for exceptions based on the class they are raised from, so this shall not be big 
problem.
Comment 1 Martin Entlicher 2008-11-26 21:23:45 UTC
*** Issue 153972 has been marked as a duplicate of this issue. ***
Comment 2 Martin Entlicher 2008-11-26 21:24:56 UTC
Planned for 7.0 at http://wiki.netbeans.org/DebuggerExceptionBP70
Comment 3 David Konecny 2008-11-26 21:59:43 UTC
In addition to well known exceptions consider catching all runtime exceptions. Thanks.
Comment 4 locked 2011-12-30 13:43:55 UTC
This should work at least in NB 7.1RC2.

Just tested by debugging

public class Test {
    public static void main(String[] args) {
        throw new ArithmeticException("foo");
    }
}

should the bug be marked as resolved?
Comment 5 Jaroslav Tulach 2016-05-25 06:05:43 UTC
Thanks.