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 205298 - NullPointerException at org.netbeans.modules.maven.j2ee.customizer.CustomizerRunWeb.initValues
Summary: NullPointerException at org.netbeans.modules.maven.j2ee.customizer.Customizer...
Status: RESOLVED FIXED
Alias: None
Product: javaee
Classification: Unclassified
Component: Maven (show other bugs)
Version: 7.1
Hardware: All All
: P3 normal with 3 votes (vote)
Assignee: Martin Janicek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-11-18 15:04 UTC by FrantaM
Modified: 2012-02-22 14:00 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 183019


Attachments
stacktrace (10.28 KB, text/plain)
2011-11-18 15:04 UTC, FrantaM
Details

Note You need to log in before you can comment on or make changes to this bug.
Description FrantaM 2011-11-18 15:04:55 UTC
Build: NetBeans IDE Dev (Build 201111160600)
VM: Java HotSpot(TM) 64-Bit Server VM, 21.0-b17, Java(TM) SE Runtime Environment, 1.7.0-b147
OS: Linux

User Comments:
FrantaM: Maven WebProject: Project Properties | Run




Stacktrace: 
java.lang.NullPointerException
   at org.netbeans.modules.maven.j2ee.customizer.CustomizerRunWeb.initValues(CustomizerRunWeb.java:204)
   at org.netbeans.modules.maven.j2ee.customizer.CustomizerRunWeb.<init>(CustomizerRunWeb.java:173)
   at org.netbeans.modules.maven.j2ee.customizer.MavenCompositePanelProvider.createComponent(MavenCompositePanelProvider.java:122)
   at org.netbeans.spi.project.ui.support.ProjectCustomizer$DelegateCategoryProvider.create(ProjectCustomizer.java:702)
   at org.netbeans.modules.project.uiapi.CustomizerPane.setCategory(CustomizerPane.java:259)
   at org.netbeans.modules.project.uiapi.CustomizerPane.access$200(CustomizerPane.java:72)
Comment 1 FrantaM 2011-11-18 15:04:58 UTC
Created attachment 113322 [details]
stacktrace
Comment 2 Martin Janicek 2011-11-24 14:11:52 UTC
This is quite weird - such a situation should never happened. Anyway I created revision web-main #542151077fde which should avoid such a NPE.
Comment 3 Quality Engineering 2011-11-25 16:22:13 UTC
Integrated into 'main-golden'
Changeset: http://hg.netbeans.org/main-golden/rev/542151077fde
User: Martin Janicek <mjanicek@netbeans.org>
Log: #205298 - NullPointerException at org.netbeans.modules.maven.j2ee.customizer.CustomizerRunWeb.initValues
Comment 4 reinouts 2011-12-06 09:24:20 UTC
How is this not a showstopper for 7.1?
Comment 5 Martin Janicek 2011-12-06 09:31:10 UTC
Well this was quite rare exception with one duplicate. I've just tried to follow described steps (that means - create maven web app and go to properties/run panel) with Netbeans 7.1 RC1 and no exception occurs.

So why should it be showstopper?
Comment 6 calvin 2011-12-06 11:21:20 UTC
I have run into this as well on 7.1 RC2
Comment 7 Martin Janicek 2011-12-15 12:04:54 UTC
Ye thats possible, the fix will be integrated for 7.2.
Comment 8 FrantaM 2011-12-15 13:24:29 UTC
(In reply to comment #2)
> This is quite weird - such a situation should never happened. Anyway I created
> revision web-main #542151077fde which should avoid such a NPE.

It seems it's caused by incorrectly loaded (web|context|pom).xml. 
After every restart of netbeans when I want to debug the project it asks me to select deployment server. Even though I always choose to remember it permanently.
Comment 9 Martin Janicek 2011-12-15 13:54:11 UTC
The problem you are describing was already fixed (see issue 206231 for more details). But it shouldn't be related to this one.
Comment 10 sdorra 2012-01-05 19:41:40 UTC
I run into the same issue with netbeans 7.1. It is possible to fix this issue manually?
Comment 11 Martin Janicek 2012-01-06 10:22:11 UTC
Sure, it is. You just need to change CustomizerRunWeb source code in the same way as it's done by my revision (http://hg.netbeans.org/main-golden/rev/542151077fde).

Because it seems that this is not so rare in 7.1 I'll consider the integration of this patch to 7.1.1 as well
Comment 12 thejosh00 2012-01-09 17:51:18 UTC
I have also run into this issue and would love to have it fixed in 7.1.1
Comment 13 todorst 2012-02-22 14:00:14 UTC
I have the same issue. It occurs when I add custom action. If the custom action is removed, the problem disappears and Run dialog is shown.
Hope this is fixed in 7.1.1