Bug 123559 - NPE at o.n.core.windows.persistence.ModeParser.addTCRef
NPE at o.n.core.windows.persistence.ModeParser.addTCRef
Status: RESOLVED FIXED
Product: platform
Classification: Unclassified
Component: Window System
6.x
All All
: P3 (vote)
: 7.0
Assigned To: Stanislav Aubrecht
issues@platform
http://statistics.netbeans.org/except...
EXCEPTIONS_REPORT
: ERGONOMICS, RANDOM
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-12-06 11:18 UTC by shabeepk
Modified: 2010-09-15 03:05 UTC (History)
9 users (show)

See Also:
Issue Type: DEFECT
:


Attachments
stacktrace (2.96 KB, text/plain)
2007-12-06 11:19 UTC, shabeepk
Details
stacktrace (3.61 KB, text/plain)
2009-03-26 19:38 UTC, Filip Zamboj
Details
stacktrace (5.10 KB, text/plain)
2009-06-14 08:28 UTC, nleck
Details
stacktrace (4.99 KB, text/plain)
2009-06-30 07:39 UTC, neilg
Details
stacktrace (4.99 KB, text/plain)
2009-06-30 07:47 UTC, neilg
Details
stacktrace (5.08 KB, text/plain)
2009-09-30 15:51 UTC, Oleg Khokhlov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description shabeepk 2007-12-06 11:18:43 UTC
Build: NetBeans IDE 6.0 (Build 200711261600)
VM: Java HotSpot(TM) Client VM, 1.6.0_01-b06
OS: Windows XP, 5.1, x86

User Comments:
Comment 1 shabeepk 2007-12-06 11:19:09 UTC
Created attachment 53938 [details]
stacktrace
Comment 2 David Simonek 2007-12-06 12:16:19 UTC
Reporter, what did you do before exception was thrown? Please specify set of steps that leads to exception, thanks.

(ccing Marek, it looks like reporter was enabling/disabling some module - is it right that winsys persistence structures
are modified in RequestProcessor thread?)
Comment 3 David Simonek 2008-01-09 10:26:16 UTC
Passing to Marek, please help me with this, thanks.
Comment 4 mslama 2008-03-18 15:38:28 UTC
So far 2 reports. It looks like some item in localList might be null. If this issue will happen again I can add some
additional checks into code to detect such state sooner and handle it better.

Parsers are modified synchronously. Winsys model change is done asynchronously in AWT thread. I do not think it can
cause any problem.

It would help if there is any reproducible case. Reporter do you remember what module(s) you installed/enabled?
Comment 5 Lukas Hasik 2008-04-10 21:22:24 UTC
moving opened issues from TM <= 6.1 to TM=Dev
Comment 6 mslama 2008-06-26 15:51:05 UTC
I do not see any way how element of localList could be null. I am not able to find proper fix without steps to
reproduce. From exception call stack it looks like some module(s)/plugin(s) was installed. I need to know what at least
to try to reproduce. Closing for now.
Comment 7 ranbato 2008-10-02 16:48:25 UTC
Reopening - reproduced in NetBeans IDE Dev (Build 200810011401)
Comment 8 mslama 2008-10-02 16:57:27 UTC
Please do you know what did you do? Have you installed any plugin/module?
Comment 9 Lukas Hasik 2008-12-04 11:33:37 UTC
unable to reproduce with NB6.5
Comment 10 Exceptions Reporter 2009-02-11 00:01:11 UTC
Reopening - reproduced in NetBeans IDE Dev (Build 200902091451)
http://statistics.netbeans.org/exceptions/detail.do?id=3242
Comment 11 Filip Zamboj 2009-03-26 19:38:04 UTC
Build: NetBeans IDE Dev (Build 200903260733)
VM: Java HotSpot(TM) Client VM, 11.2-b01, Java(TM) SE Runtime Environment, 1.6.0_12-b04
OS: Windows Vista, 6.0, x86

User Comments: 
Activating PHP after fresh install! 

Steps: 
1. install full IDE
2. create a php project 
3. while activating php you get an exception! 

This one is pretty 'ugly' and should be resolved/fixed until 6.7 beta - we can't say we have ergonomic IDE and suffer from these exceptions when activating module ... 

Stacktrace: 
java.lang.NullPointerException
        at org.netbeans.core.windows.persistence.ModeParser.addTCRef(ModeParser.java:725)
        at org.netbeans.core.windows.persistence.WindowManagerParser.addTCRef(WindowManagerParser.java:267)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.addTCRef(ModuleChangeHandler.java:433)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.processTCRef(ModuleChangeHandler.java:419)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.processDataOrFolderCreated(ModuleChangeHandler.java:315)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.fileDataCreated(ModuleChangeHandler.java:261)
Comment 12 Filip Zamboj 2009-03-26 19:38:08 UTC
Created attachment 78934 [details]
stacktrace
Comment 13 mslama 2009-05-25 11:02:35 UTC
Waiting for log from fzamboj. Without it I cannot fix it. Only thing I can do is to add some logging and wait for next
occurrence which is probably only possibility.
Comment 14 Filip Zamboj 2009-05-25 11:27:41 UTC
I can't reproduce for a long time so going back to build from March 30 and will try to send you log, asap. 
Comment 15 Filip Zamboj 2009-05-25 14:36:00 UTC
I tried on Linux and Vista on multiple builds from March, April and May. No success :(:(. I guess the idea to add
logging information into trunk is the best option in this situation. 
Comment 16 nleck 2009-06-14 08:27:51 UTC
Build: NetBeans IDE Dev (Build 200906131401)
VM: Java HotSpot(TM) Client VM, 1.5.0_18-b02, Java(TM) 2 Runtime Environment, Standard Edition, 1.5.0_18-b02
OS: SunOS, 5.10, sparc

User Comments: 
trying to open project

Stacktrace: 
java.lang.NullPointerException
        at org.netbeans.core.windows.persistence.ModeParser.addTCRef(ModeParser.java:725)
        at org.netbeans.core.windows.persistence.WindowManagerParser.addTCRef(WindowManagerParser.java:267)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.addTCRef(ModuleChangeHandler.java:433)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.processTCRef(ModuleChangeHandler.java:419)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.processDataOrFolderCreated(ModuleChangeHandler.java:315)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.fileDataCreated(ModuleChangeHandler.java:261)
Comment 17 nleck 2009-06-14 08:28:01 UTC
Created attachment 83550 [details]
stacktrace
Comment 18 neilg 2009-06-30 07:39:12 UTC
Build: NetBeans IDE 6.7 (Build 200906241340)
VM: Java HotSpot(TM) 64-Bit Server VM, 11.3-b02, Java(TM) SE Runtime Environment, 1.6.0_13-b03
OS: Linux, 2.6.28-13-generic, amd64

User Comments: 
started IDE

Stacktrace: 
java.lang.NullPointerException
        at org.netbeans.core.windows.persistence.ModeParser.addTCRef(ModeParser.java:725)
        at org.netbeans.core.windows.persistence.WindowManagerParser.addTCRef(WindowManagerParser.java:267)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.addTCRef(ModuleChangeHandler.java:433)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.processTCRef(ModuleChangeHandler.java:419)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.processDataOrFolderCreated(ModuleChangeHandler.java:315)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.fileDataCreated(ModuleChangeHandler.java:261)
Comment 19 neilg 2009-06-30 07:39:19 UTC
Created attachment 84160 [details]
stacktrace
Comment 20 neilg 2009-06-30 07:47:13 UTC
Build: NetBeans IDE 6.7 (Build 200906241340)
VM: Java HotSpot(TM) 64-Bit Server VM, 11.3-b02, Java(TM) SE Runtime Environment, 1.6.0_13-b03
OS: Linux, 2.6.28-13-generic, amd64

User Comments: 
started IDE

Stacktrace: 
java.lang.NullPointerException
        at org.netbeans.core.windows.persistence.ModeParser.addTCRef(ModeParser.java:725)
        at org.netbeans.core.windows.persistence.WindowManagerParser.addTCRef(WindowManagerParser.java:267)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.addTCRef(ModuleChangeHandler.java:433)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.processTCRef(ModuleChangeHandler.java:419)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.processDataOrFolderCreated(ModuleChangeHandler.java:315)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.fileDataCreated(ModuleChangeHandler.java:261)
Comment 21 neilg 2009-06-30 07:47:17 UTC
Created attachment 84161 [details]
stacktrace
Comment 22 neilg 2009-06-30 08:42:15 UTC
Raising to P2 as >20 duplicate exceptions.

This happened to me twice with a fresh install of NB6.7 final activating the standard Java tools as I opened a maven
project, not a good start for such a standard use case.
Comment 23 Stanislav Aubrecht 2009-07-03 16:23:35 UTC
ergonomics related, please evaluate
Comment 24 Jaroslav Tulach 2009-07-09 18:38:31 UTC
I am not sure whether I can be much helpful. I do not understand the code at all. I would start by adding asserts:

# Following Index: paths are relative to: core.windows/src/org/netbeans/core/windows/persistence
Index: ModeParser.java
--- ModeParser.java Base (BASE)
+++ ModeParser.java Locally Modified (Based On LOCAL)
@@ -690,6 +690,7 @@
             String name = (String) en.getKey();
             int index = ((Integer) en.getValue()).intValue();
             tcRefParser = (TCRefParser) localMap.remove(name);
+            assert tcRefParser != null : "No parser for " + name + " in " + tcRefParser;
             //Put instances to array according to defined order
             //Order should be defined from 0 to N-1
             //log("-- -- ADD [" + index + "]: " + tcRefParser.getName());
@@ -701,6 +702,7 @@
         //Append remaining instances if any
         for (Iterator it = localMap.keySet().iterator(); it.hasNext(); ) {
             tcRefParser = (TCRefParser) localMap.get(it.next());
+            assert tcRefParser != null : "No parser";
             localList.add(tcRefParser);
         }
Comment 25 Stanislav Aubrecht 2009-07-15 09:37:57 UTC
i added assertions as suggested
please reopen when reproduced again and attach new error messages, thanks
Comment 26 Quality Engineering 2009-07-16 05:58:41 UTC
Integrated into 'main-golden', will be available in build *200907160201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/3e226c1243c1
User: S. Aubrecht <saubrecht@netbeans.org>
Log: #123559 - added assertion to help diagnose the problem
Comment 27 Oleg Khokhlov 2009-09-30 15:51:35 UTC
Build: NetBeans IDE Dev (Build 200909290201)
VM: Java HotSpot(TM) Client VM, 14.2-b01, Java(TM) SE Runtime Environment, 1.6.0_16-b01
OS: Windows XP, 5.1, x86

User Comments: 
with new userdir: netbeans.exe --open project
- IDE starts to open project/activate JavaSE but crashes;
- after that start IDE without --open -> it will be opened as usual ergo build (all disabled);
- try to activate JavaSE -> NPE


Stacktrace: 
java.lang.NullPointerException
        at org.netbeans.core.windows.persistence.ModeParser.addTCRef(ModeParser.java:728)
        at org.netbeans.core.windows.persistence.WindowManagerParser.addTCRef(WindowManagerParser.java:267)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.addTCRef(ModuleChangeHandler.java:436)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.processTCRef(ModuleChangeHandler.java:422)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.processDataOrFolderCreated(ModuleChangeHandler.java:318)
        at org.netbeans.core.windows.persistence.ModuleChangeHandler.fileDataCreated(ModuleChangeHandler.java:264)
Comment 28 Oleg Khokhlov 2009-09-30 15:51:40 UTC
Created attachment 88610 [details]
stacktrace
Comment 29 Quality Engineering 2009-11-02 10:59:25 UTC
NetBeans.org Migration: changing resolution from LATER to WONTFIX
Comment 30 Tomas Danek 2009-12-04 05:06:53 UTC
reoepning as p3, for post 6.8 evauluation. I was able to reproduce in 6.8 rc2
Comment 31 Stanislav Aubrecht 2010-09-14 13:22:20 UTC
core-main 9940f57f0230
Comment 32 Quality Engineering 2010-09-15 03:05:10 UTC
Integrated into 'main-golden', will be available in build *201009150000* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/9940f57f0230
User: S. Aubrecht <saubrecht@netbeans.org>
Log: #123559 - NPE


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo