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.
Summary: | NullPointerException at org.netbeans.modules.java.source.classpath.CacheClassPath.<init> | ||
---|---|---|---|
Product: | java | Reporter: | sid21177 <sid21177> |
Component: | Project | Assignee: | Tomas Zezula <tzezula> |
Status: | VERIFIED FIXED | ||
Severity: | blocker | CC: | ensiketu, sustaining |
Priority: | P3 | ||
Version: | 6.x | ||
Hardware: | All | ||
OS: | All | ||
URL: | http://statistics.netbeans.org/exceptions/detail.do?id=36596 | ||
Issue Type: | DEFECT | Exception Reporter: | 36596 |
Attachments: |
stacktrace
stacktrace stacktrace stacktrace stacktrace AssertionError throw when assertions are enabled. NPE when assertions are disabled. stacktrace stacktrace stacktrace stacktrace stacktrace |
Description
sid21177
2008-04-30 18:06:33 UTC
Created attachment 60890 [details]
stacktrace
Build: NetBeans IDE 6.1 (Build 200804211638) VM: Java HotSpot(TM) Client VM, 1.6.0_03-b05, Java(TM) SE Runtime Environment, 1.6.0_03-b05 OS: Windows XP, 5.1, x86 User Comments: Created attachment 60891 [details]
stacktrace
This issue has already 10 duplicates Build: NetBeans IDE 6.1 (Build 200804211638) VM: Java HotSpot(TM) Client VM, 10.0-b19, Java(TM) SE Runtime Environment, 1.6.0_05-b13 OS: Windows XP, 5.1, x86 User Comments: When I run a Swing application, this exception is raised. Created attachment 61001 [details]
stacktrace
This issue has already 20 duplicates Build: NetBeans IDE 6.1 (Build 200804211638) VM: Java HotSpot(TM) Client VM, 10.0-b22, Java(TM) SE Runtime Environment, 1.6.0_06-b02 OS: Linux, 2.6.22.17-0.1-default, i386 User Comments: after copy/paste a project when i run it Created attachment 61183 [details]
stacktrace
Build: NetBeans IDE 6.1 (Build 200804211638) VM: Java HotSpot(TM) Client VM, 11.0-b11, Java(TM) SE Runtime Environment, 1.6.0_10-beta-b14 OS: Windows XP, 5.1, x86 User Comments: Created attachment 61218 [details]
stacktrace
To reproduce: -create a new J2SE project -remove all source roots from the project -make sure the main class *is* set -try to run the project An AssertionError is thrown when assertion are enabled, NPE when disabled (both attached, from a recent trunk build). Unless there is a reason allow null values (I do not see any, esp. considering the null values did not work till now) for ClasspathInfo.create(...), I propose to: -explicitly document that null values are not allowed+use Parameters to enforce non-null values - I can do this -fix the J2SE project not to throw the AE and not to pass null co ClasspathInfo Created attachment 61257 [details]
AssertionError throw when assertions are enabled.
Created attachment 61258 [details]
NPE when assertions are disabled.
Created attachment 61492 [details]
stacktrace
Created attachment 61962 [details]
stacktrace
Created attachment 62694 [details]
stacktrace
Created attachment 62765 [details]
stacktrace
Created attachment 63051 [details]
stacktrace
Fixed: 0e2b5e9fcc63 This issue has lots of duplicates, so it would be useful to include the fix in patch. Can someone from reporters verify the fix, please? It's not so easy to reproduce it. You have to have a jar file with main class on the classpath and set the main from the jar as a project class path. You also need to remove all source roots from project. Integrated into 'main-golden', available in NB_Trunk_Production #271 build Changeset: http://hg.netbeans.org/main/rev/0e2b5e9fcc63 User: Tomas Zezula <tzezula@netbeans.org> Log: #134280:NullPointerException at org.netbeans.modules.java.source.classpath.CacheClassPath.<init> As the nomination process goes forward with NetBeans 6.1 Patch 3 and beyond, low priority defects from P3 to P5 should include a justification and a safety assessment when nominated for patch inclusion. Could QE provide that info? Also please note that the nomination cut-off is on COB of Aug 5. Unverified bugfixes don't get into patch. cannot reproduce in trunk build, no reports after the fix -> verified justification for including in path: over 100 duplicates I've transplanted the changeset http://hg.netbeans.org/main/rev/0e2b5e9fcc63 into release61_fixes repository as http://hg.netbeans.org/release61_fixes/rev/9f7418fb410d |