Please use the Apache issue tracking system for new NetBeans issues (https://issues.apache.org/jira/projects/NETBEANS0/issues) !!
Bug 60759 - Exception when creating new Java project from existing sources
Exception when creating new Java project from existing sources
Status: RESOLVED FIXED
Product: java
Classification: Unclassified
Component: Project
4.x
All Windows ME/2000
: P2 (vote)
: 5.x
Assigned To: Tomas Zezula
issues@java
:
: 63429 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-07-07 02:13 UTC by estroh
Modified: 2005-09-14 19:11 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description estroh 2005-07-07 02:13:54 UTC
In the New Project... wizard, select Java Project with Existing Sources and
click Next.  Now, click Finish (*not* Next -- meaning that the source folders
are still unspecified).  You get the following exception:

java.lang.reflect.UndeclaredThrowableException
	at $Proxy14.actionPerformed(Unknown Source)
	at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
	at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
	at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
	at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
	at
javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:234)
	at java.awt.Component.processMouseEvent(Component.java:5488)
	at javax.swing.JComponent.processMouseEvent(JComponent.java:3093)
	at java.awt.Component.processEvent(Component.java:5253)
	at java.awt.Container.processEvent(Container.java:1966)
	at java.awt.Component.dispatchEventImpl(Component.java:3955)
	at java.awt.Container.dispatchEventImpl(Container.java:2024)
	at java.awt.Component.dispatchEvent(Component.java:3803)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4212)
	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3892)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3822)
	at java.awt.Container.dispatchEventImpl(Container.java:2010)
	at java.awt.Window.dispatchEventImpl(Window.java:1766)
	at java.awt.Component.dispatchEvent(Component.java:3803)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
	at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:234)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:153)
	at java.awt.Dialog$1.run(Dialog.java:515)
	at java.awt.Dialog.show(Dialog.java:536)
	at org.netbeans.core.windows.services.NbPresenter.superShow(NbPresenter.java:800)
	at org.netbeans.core.windows.services.NbPresenter.doShow(NbPresenter.java:843)
	at org.netbeans.core.windows.services.NbPresenter.run(NbPresenter.java:831)
	at org.openide.util.Mutex$1.run(Mutex.java:1058)
	at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:199)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
	at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:234)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
Caused by: java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	at
org.openide.util.WeakListenerImpl$ProxyListener.invoke(WeakListenerImpl.java:383)
	... 36 more
Caused by: java.lang.NullPointerException
	at
org.netbeans.modules.java.j2seproject.J2SEProjectGenerator$1.run(J2SEProjectGenerator.java:88)
	at org.openide.util.Mutex.writeAccess(Mutex.java:310)
	at
org.netbeans.modules.java.j2seproject.J2SEProjectGenerator.createProject(J2SEProjectGenerator.java:78)
	at
org.netbeans.modules.java.j2seproject.ui.wizards.NewJ2SEProjectWizardIterator.instantiate(NewJ2SEProjectWizardIterator.java:109)
	at
org.openide.loaders.TemplateWizard$Brigde2Iterator.instantiate(TemplateWizard.java:969)
	at org.openide.loaders.TemplateWizard.handleInstantiate(TemplateWizard.java:557)
	at
org.openide.loaders.TemplateWizard.instantiateNewObjects(TemplateWizard.java:396)
	at
org.openide.loaders.TemplateWizardIterImpl.instantiate(TemplateWizardIterImpl.java:218)
	at org.openide.WizardDescriptor.callInstantiate(WizardDescriptor.java:1425)
	at org.openide.WizardDescriptor.access$900(WizardDescriptor.java:63)
	at
org.openide.WizardDescriptor$Listener.actionPerformed(WizardDescriptor.java:1327)
[catch] ... 41 more
==>
java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	at
org.openide.util.WeakListenerImpl$ProxyListener.invoke(WeakListenerImpl.java:383)
	at $Proxy14.actionPerformed(Unknown Source)
	at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
	at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
	at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
	at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
	at
javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:234)
	at java.awt.Component.processMouseEvent(Component.java:5488)
	at javax.swing.JComponent.processMouseEvent(JComponent.java:3093)
	at java.awt.Component.processEvent(Component.java:5253)
	at java.awt.Container.processEvent(Container.java:1966)
	at java.awt.Component.dispatchEventImpl(Component.java:3955)
	at java.awt.Container.dispatchEventImpl(Container.java:2024)
	at java.awt.Component.dispatchEvent(Component.java:3803)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4212)
	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3892)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3822)
	at java.awt.Container.dispatchEventImpl(Container.java:2010)
	at java.awt.Window.dispatchEventImpl(Window.java:1766)
	at java.awt.Component.dispatchEvent(Component.java:3803)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
	at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:234)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:153)
	at java.awt.Dialog$1.run(Dialog.java:515)
	at java.awt.Dialog.show(Dialog.java:536)
	at org.netbeans.core.windows.services.NbPresenter.superShow(NbPresenter.java:800)
	at org.netbeans.core.windows.services.NbPresenter.doShow(NbPresenter.java:843)
	at org.netbeans.core.windows.services.NbPresenter.run(NbPresenter.java:831)
	at org.openide.util.Mutex$1.run(Mutex.java:1058)
	at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:199)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
	at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:234)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
Caused by: java.lang.NullPointerException
	at
org.netbeans.modules.java.j2seproject.J2SEProjectGenerator$1.run(J2SEProjectGenerator.java:88)
	at org.openide.util.Mutex.writeAccess(Mutex.java:310)
	at
org.netbeans.modules.java.j2seproject.J2SEProjectGenerator.createProject(J2SEProjectGenerator.java:78)
	at
org.netbeans.modules.java.j2seproject.ui.wizards.NewJ2SEProjectWizardIterator.instantiate(NewJ2SEProjectWizardIterator.java:109)
	at
org.openide.loaders.TemplateWizard$Brigde2Iterator.instantiate(TemplateWizard.java:969)
	at org.openide.loaders.TemplateWizard.handleInstantiate(TemplateWizard.java:557)
	at
org.openide.loaders.TemplateWizard.instantiateNewObjects(TemplateWizard.java:396)
	at
org.openide.loaders.TemplateWizardIterImpl.instantiate(TemplateWizardIterImpl.java:218)
	at org.openide.WizardDescriptor.callInstantiate(WizardDescriptor.java:1425)
	at org.openide.WizardDescriptor.access$900(WizardDescriptor.java:63)
	at
org.openide.WizardDescriptor$Listener.actionPerformed(WizardDescriptor.java:1327)
[catch] ... 41 more
==>
java.lang.NullPointerException
	at
org.netbeans.modules.java.j2seproject.J2SEProjectGenerator$1.run(J2SEProjectGenerator.java:88)
	at org.openide.util.Mutex.writeAccess(Mutex.java:310)
	at
org.netbeans.modules.java.j2seproject.J2SEProjectGenerator.createProject(J2SEProjectGenerator.java:78)
	at
org.netbeans.modules.java.j2seproject.ui.wizards.NewJ2SEProjectWizardIterator.instantiate(NewJ2SEProjectWizardIterator.java:109)
	at
org.openide.loaders.TemplateWizard$Brigde2Iterator.instantiate(TemplateWizard.java:969)
	at org.openide.loaders.TemplateWizard.handleInstantiate(TemplateWizard.java:557)
	at
org.openide.loaders.TemplateWizard.instantiateNewObjects(TemplateWizard.java:396)
	at
org.openide.loaders.TemplateWizardIterImpl.instantiate(TemplateWizardIterImpl.java:218)
	at org.openide.WizardDescriptor.callInstantiate(WizardDescriptor.java:1425)
	at org.openide.WizardDescriptor.access$900(WizardDescriptor.java:63)
	at
org.openide.WizardDescriptor$Listener.actionPerformed(WizardDescriptor.java:1327)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	at
org.openide.util.WeakListenerImpl$ProxyListener.invoke(WeakListenerImpl.java:383)
	at $Proxy14.actionPerformed(Unknown Source)
	at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
	at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
	at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
	at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
	at
javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:234)
	at java.awt.Component.processMouseEvent(Component.java:5488)
	at javax.swing.JComponent.processMouseEvent(JComponent.java:3093)
	at java.awt.Component.processEvent(Component.java:5253)
	at java.awt.Container.processEvent(Container.java:1966)
	at java.awt.Component.dispatchEventImpl(Component.java:3955)
	at java.awt.Container.dispatchEventImpl(Container.java:2024)
	at java.awt.Component.dispatchEvent(Component.java:3803)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4212)
	at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3892)
	at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3822)
	at java.awt.Container.dispatchEventImpl(Container.java:2010)
	at java.awt.Window.dispatchEventImpl(Window.java:1766)
	at java.awt.Component.dispatchEvent(Component.java:3803)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
	at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:234)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:153)
	at java.awt.Dialog$1.run(Dialog.java:515)
	at java.awt.Dialog.show(Dialog.java:536)
	at org.netbeans.core.windows.services.NbPresenter.superShow(NbPresenter.java:800)
	at org.netbeans.core.windows.services.NbPresenter.doShow(NbPresenter.java:843)
	at org.netbeans.core.windows.services.NbPresenter.run(NbPresenter.java:831)
	at org.openide.util.Mutex$1.run(Mutex.java:1058)
[catch] at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:199)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
	at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:234)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)

The path I was using to try to create the project does not have a src subfolder
-- in case that makes a difference.  If I click on Next and select a source
folder, everything works fine.  Perhaps a simple fix would be to disable the
Finish button for the second wizard screen.
Comment 1 Jan Chalupa 2005-07-20 14:53:27 UTC
This looks more serious than a P3. I've seen a report of the same problem from
another user. ->P2
Comment 2 Tomas Zezula 2005-07-20 15:18:04 UTC
The J2SEProjectGenerator::createProject gets the null value of sourceFolders.
The sources panel should init it even when no sources are defined.
Comment 3 Tomas Zezula 2005-09-07 17:05:33 UTC
Checking in
j2seproject/src/org/netbeans/modules/java/j2seproject/ui/wizards/NewJ2SEProjectWizardIterator.java;
/cvs/java/j2seproject/src/org/netbeans/modules/java/j2seproject/ui/wizards/NewJ2SEProjectWizardIterator.java,v
 <--  NewJ2SEProjectWizardIterator.java
new revision: 1.28; previous revision: 1.27
done
Checking in
j2seproject/src/org/netbeans/modules/java/j2seproject/ui/wizards/PanelSourceFolders.java;
/cvs/java/j2seproject/src/org/netbeans/modules/java/j2seproject/ui/wizards/PanelSourceFolders.java,v
 <--  PanelSourceFolders.java
new revision: 1.41; previous revision: 1.40
done
Comment 4 Tomas Zezula 2005-09-14 19:11:55 UTC
*** Issue 63429 has been marked as a duplicate of this issue. ***


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