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.
Build 20050324-0408 1) Create WebFreeform project with a java class 2) Move class to another package (drag and drop) 3) Refactoring window appears 4) EXCEPTION - java.lang.NullPointerException see attachment
Created attachment 21098 [details] java.lang.NullPointerException at org.netbeans.modules.refactoring.ui.RefactoringPanel.createNode(RefactoringPanel.java:448)
1) It works fine in Java freeform project. 2) It worked fine in build 200503141900 -> reassigning to PetrPisl.
Martin, can you please look at this? Thanks.
Could you attach the freeform files and provide steps how did you create it? Thanks. This seems to be a problem in web freeform, not in refactoring or j2ee refactoring.
Little bit different exception (see attachemnt) on this project (create Freeform project from attached sources without any classpath settings, just use default detected values)
Created attachment 21110 [details] java.lang.NullPointerException at org.netbeans.modules.refactoring.ui.RefactoringOperationListener.operationMove(RefactoringOperationListener.java:137)
Created attachment 21111 [details] Freeform project sources (without nbproject - just create it with wizard defaults)
I'm still not able to reproduce with latest sources. I followed this steps: 1. Unzip the attachment to some folder 2. Run IDE with fresh userdir 3. Create web freeform, navigate to unzipped folder, click next-next-...-finish 4. Select Timer...java and drag and drop it to other package 5. Refactoring dialog is shown, everything is fine 6. Tried to stop/start ide and again step 4 7. Still works fine I must be missing something (or was it fixed in the meantime)?
Martine, I followed your steps with different result on WinXP SP2, JDK 1.5.0_02-fcs, see my comments: Your steps 1-4 5-B) Refactoring dialog appears, press Next 6-B) Refactoring Output window appears, but it is empty 7-B) EXCEPTION dialog appears (Refactoring Output is still empty) -- see attached screenshot
Created attachment 21139 [details] Exception screenshot after Moving class to 'a' package
BTW: the exception in step 7-B is the first attached exception attached to this issue (my 2nd comment) - java.lang.NullPointerException at org.netbeans.modules.refactoring.ui.RefactoringPanel.createNode(RefactoringPanel.java:448)
I tried on jdk 1.5.0_01 and still works, interesting, is this a windows only issue?
It looks like a problem with ClassPath. ClassPath cp = ClassPath.getClassPath(file, ClassPath.SOURCE); cp.getResourceName(file) returns null - it is strange, isn't it?
Reproducible on WinXP SP2 with JDK 1.5.0_01-b06. Probably Win specific problem.
This is a regression caused by recent fixes in classpath area for web freeform. PetrP already has some changes prepared that fix the problem -> reassigning.
It should be fixed in the trunk.
Verified in 200503301800.