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 115462

Summary: java.lang.NullPointerException
Product: java Reporter: athompson <athompson>
Component: RefactoringAssignee: Jan Pokorsky <jpokorsky>
Status: REOPENED ---    
Severity: blocker CC: brettryan
Priority: P3    
Version: 6.x   
Hardware: All   
OS: All   
URL: http://statistics.netbeans.org/exceptions/detail.do?id=3750
Issue Type: DEFECT Exception Reporter: 3750
Attachments: stacktrace
stacktrace
stacktrace
messages.log with varying exceptions

Description athompson 2007-09-13 14:39:46 UTC
Build: NetBeans IDE Dev (Build 200709130000)
VM: Java HotSpot(TM) Client VM, 1.6.0_02-b06
OS: Windows XP, 5.1, x86

User Comments: 
trying to delete java file
Comment 1 athompson 2007-09-13 14:39:50 UTC
Created attachment 48749 [details]
stacktrace
Comment 2 Jan Becicka 2007-09-14 12:05:42 UTC
Any steps to reproduce? It works for me.
Comment 3 athompson 2007-09-14 14:21:50 UTC
no, just that time, so i hit the 'review and report' button.  earlier, there was another IOOBE when trying to edit the
file (reported before this one), so i tried to delete the file and start over.
Comment 4 Jan Becicka 2007-10-03 12:34:33 UTC
Can you attach whole messages.log? Thanks.
Comment 5 athompson 2007-10-04 15:53:47 UTC
sorry, i no longer have the log files.
Comment 6 Jan Becicka 2007-10-04 16:17:12 UTC
OK. Please attach log file if it happens again.
Comment 7 eamsull 2007-10-31 23:48:35 UTC
Build: NetBeans IDE 6.0 Beta 1 (Build 200709141330)
VM: Java HotSpot(TM) Client VM, 1.6.0-b105
OS: Linux, 2.6.20-16-generic, i386

User Comments: 
I right clicked on a file that I wanted to delete in the projects window
Comment 8 eamsull 2007-10-31 23:48:43 UTC
Created attachment 52200 [details]
stacktrace
Comment 9 princefafa 2008-01-17 10:24:34 UTC
Build: NetBeans IDE 6.0 (Build 200711261600)
VM: Java HotSpot(TM) Client VM, 1.6.0_02-b05
OS: Windows XP, 5.1, x86

User Comments: 
Comment 10 princefafa 2008-01-17 10:24:43 UTC
Created attachment 55189 [details]
stacktrace
Comment 11 Jiri Prox 2008-04-11 01:47:30 UTC
moving opened issues from TM <= 6.1 to TM=Dev
Comment 12 Exceptions Reporter 2008-07-16 22:34:25 UTC
This issue has already 5 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=3750
Comment 13 Jan Pokorsky 2008-07-22 10:17:16 UTC
It appears that java model is not able to resolve TreePath from TreePathHandle that was created for top level class of
the selected java file.
Unfortunately I have not been able to reproduce it with NetBeans 6.5 Dev (Build 080718). So I have added some logging
that should bring more details about what is wrong. If you encounter this again please attach your
{nb.userdir}/var/log/messages.log and if possible the deleted java file or its skeleton (omit methods) too.

http://hg.netbeans.org/main/rev/8ea5f68c660f
Comment 14 Jiri Prox 2008-12-08 16:34:46 UTC
Reporter didn't provided required information for more than 14 days. 
I'm closing this issue as worksforme, as we are not able to reproduce it with available information. 
Please, feel free to reopen when you face the problem again but attach the additional info.

thank you for report
Comment 15 brettryan 2016-08-15 06:11:05 UTC
Created attachment 161663 [details]
messages.log with varying exceptions

Was deleting a file within a maven archetype project.
Comment 16 brettryan 2016-08-15 06:20:57 UTC
Can reproduce with the following.


Steps to Reproduce
==================

1. Create a new archetype project

mvn archetype:generate \
    -DgroupId=example.com \
    -DartifactId=my-archetype \
    -DarchetypeArtifactId=maven-archetype-archetype

2. Open the project in the Editor.
3. Expand Other Sources > src/main/resources > archetype-resources.src.test.java
4. Delete AppTest.java


Result
======

Following exception error is produced.

java.lang.NullPointerException: Please attach your {nb.userdir}/var/log/messages.log to http://www.netbeans.org/issues/show_bug.cgi?id=115462
handle: TreePathHandle[delegate:TreeDelegate[kind:CLASS, enclosingElement:ElementHandle[kind=CLASS; sigs=$drunkendev.com.AppTest ], file:/Users/bryan/Development/drunkendev/app-base-archtype/src/main/resources/archetype-resources/src/test/java/AppTest.java@19648399:3d7bb501]]
classpath: ClasspathInfo [boot: /Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/resources.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/rt.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/sunrsasign.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/jsse.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/jce.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/charsets.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/jfr.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/cldrdata.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/dnsns.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/jaccess.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/jfxrt.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/localedata.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/nashorn.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/sunec.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/sunjce_provider.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/sunpkcs11.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/zipfs.jar:/System/Library/Java/Extensions/MRJToolkit.jar, compile: , src: /Users/bryan/Development/drunkendev/app-base-archtype/src/main/java:/Users/bryan/Development/drunkendev/app-base-archtype/src/main/resources, internal boot: /Users/bryan/Library/Caches/NetBeans/dev/index/s613/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/resources.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s614/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/rt.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s615/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/sunrsasign.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s616/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/jsse.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s617/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/jce.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s618/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/charsets.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s619/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/jfr.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s620/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/classes:/Users/bryan/Library/Caches/NetBeans/dev/index/s621/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/cldrdata.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s622/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/dnsns.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s623/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/jaccess.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s624/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/jfxrt.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s625/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/localedata.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s626/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/nashorn.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s627/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/sunec.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s628/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/sunjce_provider.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s629/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/sunpkcs11.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s630/java/15/classes:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/jre/lib/ext/zipfs.jar:/Users/bryan/Library/Caches/NetBeans/dev/index/s23/java/15/classes:/System/Library/Java/Extensions/MRJToolkit.jar, internal compile: , internal src: /Users/bryan/Development/drunkendev/app-base-archtype/src/main/resources, internal out: /Users/bryan/Library/Caches/NetBeans/dev/index/s1439/java/15/classes]
	at org.netbeans.modules.refactoring.java.ui.SafeDeletePanel$1.run(SafeDeletePanel.java:180)
	at org.netbeans.modules.refactoring.java.ui.SafeDeletePanel$1.run(SafeDeletePanel.java:166)
	at org.netbeans.api.java.source.JavaSource$MultiTask.run(JavaSource.java:486)
	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.refactoring.java.ui.SafeDeletePanel.initialize(SafeDeletePanel.java:166)
	at org.netbeans.modules.refactoring.spi.impl.ParametersPanel$12.run(ParametersPanel.java:654)
	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)
Caused: org.openide.util.RequestProcessor$FastItem: task failed due to
Comment 17 brettryan 2016-08-15 06:22:01 UTC
fyi, no more details appear int he exception dialog.