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 238583 - IllegalArgumentException: Root cannot be null.
Summary: IllegalArgumentException: Root cannot be null.
Status: RESOLVED FIXED
Alias: None
Product: projects
Classification: Unclassified
Component: Maven (show other bugs)
Version: 7.4
Hardware: All All
: P3 normal (vote)
Assignee: Tomas Stupka
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-11-20 04:25 UTC by Exceptions Reporter
Modified: 2016-08-04 02:03 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter: 205425


Attachments
stacktrace (5.09 KB, text/plain)
2013-11-20 04:25 UTC, Exceptions Reporter
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Exceptions Reporter 2013-11-20 04:25:07 UTC
This bug was originally marked as duplicate of bug 181589, that is already resolved. This bug is still valid, so this seems to be another bug, but it might be related.

Build: NetBeans IDE 7.4 Beta (Build 201307092200)
VM: Java HotSpot(TM) 64-Bit Server VM, 23.25-b01, Java(TM) SE Runtime Environment, 1.7.0_25-b15
OS: Mac OS X

User Comments:
GUEST: Using pom with SAML

GUEST: <Please provide a description of the problem or the steps to reproduce>

GUEST: Open projec




Stacktrace: 
java.lang.IllegalArgumentException: Root cannot be null.
   at org.netbeans.modules.java.classpath.SimplePathResourceImplementation.verify(SimplePathResourceImplementation.java:85)
   at org.netbeans.modules.java.classpath.SimplePathResourceImplementation.verify(SimplePathResourceImplementation.java:68)
   at org.netbeans.modules.java.classpath.SimplePathResourceImplementation.<init>(SimplePathResourceImplementation.java:126)
   at org.netbeans.spi.java.classpath.support.ClassPathSupport.createResource(ClassPathSupport.java:77)
   at org.netbeans.modules.maven.classpath.EndorsedClassPathImpl.getResources(EndorsedClassPathImpl.java:138)
   at org.netbeans.modules.maven.classpath.BootClassPathImpl.getResources(BootClassPathImpl.java:98)
Comment 1 Exceptions Reporter 2013-11-20 04:25:09 UTC
Created attachment 142383 [details]
stacktrace
Comment 2 Tomas Zezula 2014-03-28 08:13:29 UTC
The maven EndorsedClassPathImpl calls ClassPathSupport.createResource(URL) with null.
Comment 3 Tomas Stupka 2014-05-16 14:32:25 UTC
fixed in scope of #235687 - IllegalArgumentException: Root cannot be null
Comment 4 juanmf 2016-07-23 00:08:02 UTC
Sorry to REOPEN, dunno if the comment will be seen if not.

I'm having the same error in a mvn project when ctrl+clicking a class name defined in a dependency, for which I've downloaded sources before. The only way to see the src is manually browsing dependencies (after guessing in which one is the class of interest) and clicking on the class.  

Netbeans details:

Product Version: NetBeans IDE 8.1 (Build 201510222201)
Updates: Updates available to version NetBeans 8.1 Patch 1
Java: 1.8.0_65; Java HotSpot(TM) 64-Bit Server VM 25.65-b01
Runtime: Java(TM) SE Runtime Environment 1.8.0_65-b17
System: Linux version 3.13.0-32-generic running on amd64; UTF-8; en_US (nb)
User directory: /home/juan.fernandez/.netbeans/8.1
Cache directory: /home/juan.fernandez/.cache/netbeans/8.1




Stack trace:
java.lang.IllegalArgumentException: Root cannot be null.
	at org.netbeans.modules.java.classpath.SimplePathResourceImplementation.verify(SimplePathResourceImplementation.java:85)
	at org.netbeans.modules.java.classpath.SimplePathResourceImplementation.verify(SimplePathResourceImplementation.java:68)
	at org.netbeans.modules.java.classpath.SimplePathResourceImplementation.<init>(SimplePathResourceImplementation.java:131)
	at org.netbeans.spi.java.classpath.support.ClassPathSupport.createResource(ClassPathSupport.java:77)
	at org.netbeans.modules.maven.queries.RepositoryMavenCPProvider.createCompileCPI(RepositoryMavenCPProvider.java:205)
	at org.netbeans.modules.maven.queries.RepositoryMavenCPProvider.findClassPath(RepositoryMavenCPProvider.java:137)
	at org.netbeans.api.java.classpath.ClassPath.getClassPath(ClassPath.java:674)
	at org.netbeans.api.java.source.ClasspathInfo.create(ClasspathInfo.java:298)
	at org.netbeans.api.java.source.ClasspathInfo.create(ClasspathInfo.java:272)
	at org.netbeans.modules.java.source.parsing.JavacParser.init(JavacParser.java:270)
	at org.netbeans.modules.java.source.parsing.JavacParser.parseImpl(JavacParser.java:405)
	at org.netbeans.modules.java.source.parsing.JavacParser.parse(JavacParser.java:348)
	at org.netbeans.modules.parsing.impl.TaskProcessor.callParse(TaskProcessor.java:621)
	at org.netbeans.modules.parsing.impl.SourceCache.getResult(SourceCache.java:251)
	at org.netbeans.modules.parsing.api.ResultIterator.getParserResult(ResultIterator.java:138)
	at org.netbeans.api.java.source.JavaSource$MultiTask.run(JavaSource.java:478)
	at org.netbeans.modules.parsing.impl.TaskProcessor.callUserTask(TaskProcessor.java:609)
	at org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:153)
	at org.netbeans.modules.parsing.api.ParserManager$UserTaskAction.run(ParserManager.java:137)
	at org.netbeans.modules.parsing.impl.TaskProcessor$2.call(TaskProcessor.java:204)
	at org.netbeans.modules.parsing.impl.TaskProcessor$2.call(TaskProcessor.java:201)
	at org.netbeans.modules.masterfs.filebasedfs.utils.FileChangedManager.priorityIO(FileChangedManager.java:176)
	at org.netbeans.modules.masterfs.providers.ProvidedExtensions.priorityIO(ProvidedExtensions.java:360)
	at org.netbeans.modules.parsing.nb.DataObjectEnvFactory.runPriorityIO(DataObjectEnvFactory.java:141)
	at org.netbeans.modules.parsing.impl.Utilities.runPriorityIO(Utilities.java:88)
	at org.netbeans.modules.parsing.impl.TaskProcessor.runUserTask(TaskProcessor.java:201)
	at org.netbeans.modules.parsing.api.ParserManager.parse(ParserManager.java:104)
	at org.netbeans.api.java.source.JavaSource.runUserActionTaskImpl(JavaSource.java:436)
	at org.netbeans.api.java.source.JavaSource.runUserActionTask(JavaSource.java:407)
	at org.netbeans.modules.java.source.JavadocEnv.getRawCommentFor(JavadocEnv.java:265)
	at org.netbeans.modules.java.source.JavadocEnv.access$1400(JavadocEnv.java:88)
	at org.netbeans.modules.java.source.JavadocEnv$JavadocMethod.documentation(JavadocEnv.java:364)
	at com.sun.tools.javadoc.DocImpl.comment(DocImpl.java:129)
	at com.sun.tools.javadoc.ExecutableMemberDocImpl.paramTags(ExecutableMemberDocImpl.java:139)
	at org.netbeans.modules.javadoc.hints.Analyzer.analyze(Analyzer.java:203)
	at org.netbeans.modules.javadoc.hints.JavadocHint.errorHint(JavadocHint.java:217)
	at sun.reflect.GeneratedMethodAccessor84.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:497)
[catch] at org.netbeans.modules.java.hints.providers.code.CodeHintProviderImpl$WorkerImpl.createErrors(CodeHintProviderImpl.java:339)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker.runHint(HintsInvoker.java:810)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker.access$400(HintsInvoker.java:112)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker$ScannerImpl.runAndAdd(HintsInvoker.java:669)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker$ScannerImpl.scan(HintsInvoker.java:688)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker$ScannerImpl.scan(HintsInvoker.java:622)
	at com.sun.source.util.TreeScanner.scanAndReduce(TreeScanner.java:81)
	at com.sun.source.util.TreeScanner.scan(TreeScanner.java:91)
	at org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:103)
	at com.sun.source.util.TreeScanner.scanAndReduce(TreeScanner.java:99)
	at com.sun.source.util.TreeScanner.visitClass(TreeScanner.java:133)
	at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:725)
	at com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:68)
	at org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:94)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker$ScannerImpl.scan(HintsInvoker.java:694)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker$ScannerImpl.scan(HintsInvoker.java:622)
	at com.sun.source.util.TreeScanner.scan(TreeScanner.java:91)
	at org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:103)
	at com.sun.source.util.TreeScanner.scanAndReduce(TreeScanner.java:99)
	at com.sun.source.util.TreeScanner.visitCompilationUnit(TreeScanner.java:120)
	at com.sun.tools.javac.tree.JCTree$JCCompilationUnit.accept(JCTree.java:551)
	at com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:50)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker$ScannerImpl.scan(HintsInvoker.java:713)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker.computeHintsImpl(HintsInvoker.java:257)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker.computeHints(HintsInvoker.java:240)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker.computeHints(HintsInvoker.java:210)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker.computeHints(HintsInvoker.java:183)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsInvoker.computeHints(HintsInvoker.java:150)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsTask.run(HintsTask.java:137)
	at org.netbeans.modules.java.hints.spiimpl.hints.HintsTask.run(HintsTask.java:88)
	at org.netbeans.modules.java.source.JavaSourceAccessor$CancelableTaskWrapper.run(JavaSourceAccessor.java:298)
	at org.netbeans.modules.parsing.impl.TaskProcessor.callParserResultTask(TaskProcessor.java:584)
	at org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.run(TaskProcessor.java:809)
	at org.openide.util.lookup.Lookups.executeWith(Lookups.java:304)
	at org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.execute(TaskProcessor.java:725)
	at org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:686)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1443)
	at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:68)
	at org.openide.util.lookup.Lookups.executeWith(Lookups.java:303)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2058)
Comment 5 juanmf 2016-07-23 00:26:58 UTC
Adding to https://netbeans.org/bugzilla/show_bug.cgi?id=238583#c4

Just downloaded updates and nothing changed.
Tried deleting Cache directory: /home/juan.fernandez/.cache/netbeans/8.1
same results.

Thanks.
Comment 6 Tomas Stupka 2016-08-03 11:06:39 UTC
fixed in jet-main #0fedd085fbef
Comment 7 Quality Engineering 2016-08-04 02:03:53 UTC
Integrated into 'main-silver', will be available in build *201608040002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/0fedd085fbef
User: Tomas Stupka <tstupka@netbeans.org>
Log: Issue #238583 - IllegalArgumentException: Root cannot be null.