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 216576 - NullPointerException at org.netbeans.modules.web.javascript.debugger.browser.NetBeansJavaScriptDebuggerFactoryImpl.createDebuggingSession
Summary: NullPointerException at org.netbeans.modules.web.javascript.debugger.browser....
Status: VERIFIED FIXED
Alias: None
Product: javascript
Classification: Unclassified
Component: Debugger (show other bugs)
Version: 7.3
Hardware: All All
: P2 normal (vote)
Assignee: David Konecny
URL:
Keywords:
: 217219 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-08-09 08:40 UTC by Jiri Skrivanek
Modified: 2012-09-03 12:56 UTC (History)
8 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 191402


Attachments
stacktrace (1.91 KB, text/plain)
2012-08-09 08:40 UTC, Jiri Skrivanek
Details
stacktrace (1.91 KB, text/plain)
2012-08-09 10:51 UTC, Vladimir Riha
Details
stacktrace (1.91 KB, text/plain)
2012-08-09 12:39 UTC, Jiri Skrivanek
Details
stacktrace (1.92 KB, text/plain)
2012-08-10 08:18 UTC, Jan Becicka
Details
stacktrace (1.91 KB, text/plain)
2012-08-13 08:33 UTC, Jiri Skrivanek
Details
stacktrace (1.92 KB, text/plain)
2012-08-13 09:12 UTC, Jan Stola
Details
stacktrace (1.91 KB, text/plain)
2012-08-13 11:36 UTC, Petr Jiricka
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Skrivanek 2012-08-09 08:40:18 UTC
Build: NetBeans IDE Dev (Build EaselCSS-463-on-20120809)
VM: Java HotSpot(TM) 64-Bit Server VM, 23.2-b09, Java(TM) SE Runtime Environment, 1.7.0_06-b22
OS: Windows 7

User Comments:
jskrivanek: Run html file in embedded browser - no breakpoint set.

johnjullion: running any file in internal or external browser




Stacktrace: 
java.lang.NullPointerException
   at org.netbeans.modules.web.javascript.debugger.browser.NetBeansJavaScriptDebuggerFactoryImpl.createDebuggingSession(NetBeansJavaScriptDebuggerFactoryImpl.java:64)
   at org.netbeans.core.browser.webview.HtmlBrowserImpl$1.run(HtmlBrowserImpl.java:143)
   at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1452)
   at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2032)
Comment 1 Jiri Skrivanek 2012-08-09 08:40:19 UTC
Created attachment 122904 [details]
stacktrace
Comment 2 Vladimir Riha 2012-08-09 10:51:46 UTC
Created attachment 122915 [details]
stacktrace

running html file (with some breakpoints) in JavaFX browser
Comment 3 Jiri Skrivanek 2012-08-09 12:39:46 UTC
Created attachment 122927 [details]
stacktrace
Comment 4 Jan Becicka 2012-08-10 08:18:46 UTC
Created attachment 122974 [details]
stacktrace
Comment 5 Exceptions Reporter 2012-08-10 08:18:51 UTC
This bug already has 5 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=191402
Comment 6 Jiri Skrivanek 2012-08-13 08:33:50 UTC
Created attachment 123026 [details]
stacktrace

Run html file in embedded browser.
Comment 7 Jan Stola 2012-08-13 09:12:47 UTC
Created attachment 123035 [details]
stacktrace

1. Run HTML file (in Client Side Project) with JavaFX Embedded Browser configuration.
2. Close the resulting Web Browser window.
3. Run the file again
    => NPE is thrown.
Comment 8 Petr Jiricka 2012-08-13 11:36:47 UTC
Created attachment 123039 [details]
stacktrace

1. Running HTML project in the embedded browser
2. Closing the embedded browser window
3. Runing the project again
Comment 9 Petr Jiricka 2012-08-13 11:37:39 UTC
Martin, I guess this should be fixed by you?
Comment 10 Jan Stola 2012-08-13 11:41:29 UTC
> Martin, I guess this should be fixed by you?

The NPE is just a consequence of project context not being correctly initialized in HtmlBrowserImpl. This initialization is what must be fixed and this is David's area.
Comment 11 Petr Jiricka 2012-08-13 12:11:21 UTC
Ok, understood.
Comment 12 David Konecny 2012-08-13 23:40:35 UTC
8140cf795b4c
Comment 13 Exceptions Reporter 2012-08-14 04:12:48 UTC
This bug already has 10 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=191402
Comment 14 Stanislav Aubrecht 2012-08-22 11:48:49 UTC
I can reproduce this issue by opening the default embedded browser using menu 'View - Web browser'. The debugger is trying to initialize even though it isn't a 'developer' browser window.
Comment 15 Stanislav Aubrecht 2012-08-22 11:52:51 UTC
(In reply to comment #14)
> I can reproduce this issue by opening the default embedded browser using menu
> 'View - Web browser'. The debugger is trying to initialize even though it isn't
> a 'developer' browser window.

Fixed in web-main 9b86ecf460cd
Comment 16 Stanislav Aubrecht 2012-08-22 13:37:11 UTC
*** Bug 217219 has been marked as a duplicate of this bug. ***
Comment 17 David Konecny 2012-08-22 21:18:27 UTC
Thanks Standa. I applied the same fix also for external browser. 45d4bb5c4944

The "View" action should be removed from HTML dataobject in HTML5Project. I'm not sure how easy that it is to do - filed as issue 217253.
Comment 18 Quality Engineering 2012-09-03 12:56:28 UTC
Integrated into 'main-golden', will be available in build *201209031048* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/8140cf795b4c
User: David Konecny <dkonecny@netbeans.org>
Log: #216576 - NullPointerException at org.netbeans.modules.web.javascript.debugger.browser.NetBeansJavaScriptDebuggerFactoryImpl.createDebuggingSession