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: NetBeans IDE 8.0.2 (Build 201411181905) VM: OpenJDK 64-Bit Server VM, 24.65-b04, OpenJDK Runtime Environment, 1.7.0_65-b32 OS: Linux User Comments: bruno.flavio: Happens when using the wizard to create a grails taglib. 1. Create new grails application 2. Right-click project -> New Grails Tag Library 3. Use the default name or a name in accordance with the specification: *TagLib 4. NullPointerException is thrown. GUEST: trying to create new grails taglib GUEST: Adding a taglib GUEST: Tengo este error al tratar de crear un nuevo tagLib con groovy en grails. GUEST: <Please provide a description of the problem or the steps to reproduce> please let me know what problem is this, when i tried to create a taglib GUEST: Selected Tag Libraries New Grails TagLibrary named the taglib "DateTagLib" and pressed "Finish" GUEST: creating taglib in grails GUEST: Creating a tag library: right-click on the project, select new Grails Tag Library, browse to a folder, finish. The caption changes from Create Tag Library to "New file", and the form does not close. GUEST: Encountered exception attempting to execution New --> Groovy --> Grails Tag Library GUEST: ??Grails????? Stacktrace: java.lang.NullPointerException at org.netbeans.modules.groovy.grailsproject.ui.wizards.GrailsArtifactWizardIterator.instantiate(GrailsArtifactWizardIterator.java:177) at org.openide.loaders.TemplateWizard$InstantiatingIteratorBridge.instantiate(TemplateWizard.java:1044) at org.openide.loaders.TemplateWizard.handleInstantiate(TemplateWizard.java:605) at org.openide.loaders.TemplateWizard.instantiateNewObjects(TemplateWizard.java:439) at org.openide.loaders.TemplateWizardIterImpl.instantiate(TemplateWizardIterImpl.java:253) at org.openide.loaders.TemplateWizardIteratorWrapper$ProgressInstantiatingIterator.instantiate(TemplateWizardIteratorWrapper.java:180)
Created attachment 152304 [details] stacktrace
Created attachment 156299 [details] Proposed patch: fix the Tag Library template registration id. The template implementation for the groovy plugin expects the taglibrary template id to be 'TagLib': http://hg.netbeans.org/main-silver/file/6b5ae20e6f7a/groovy.grailsproject/src/org/netbeans/modules/groovy/grailsproject/ui/TemplatesImpl.java#l70 However, the template was being registered as 'TagLibrary': http://hg.netbeans.org/main-silver/file/6b5ae20e6f7a/groovy.grailsproject/src/org/netbeans/modules/groovy/grailsproject/ui/wizards/GrailsTemplates.java#l116 This patch fixes the registration id and changes the displayName label to the same value to maintain coherency.
Jiri: I'm adding you as CC so this can be integrated if you find that the proposed patch is OK.
I think the patch is safe hence I integrated it as http://hg.netbeans.org/core-main/rev/c7b7e5dd5c18. Thanks for the contribution Bruno!
Integrated into 'main-silver', will be available in build *201509250002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/c7b7e5dd5c18 User: Jiri Kovalsky <jkovalsky@netbeans.org> Log: Matching Groovy tag library template ID with expected implementation value. Task #250798 - NullPointerException at org.netbeans.modules.groovy.grailsproject.ui.wizards.GrailsArtifactWizardIterator.instantiate
"Verified working with *201512310002* on Grails 3.0.4 and 2.5.1."