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 169994 - NoClassDefFoundError: Could not initialize class org.netbeans.modules.ant.freeform.spi.support.Util
Summary: NoClassDefFoundError: Could not initialize class org.netbeans.modules.ant.fre...
Status: RESOLVED FIXED
Alias: None
Product: projects
Classification: Unclassified
Component: Ant Freeform (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Jesse Glick
URL: http://statistics.netbeans.org/except...
Keywords: RANDOM
: 169992 (view as bug list)
Depends on:
Blocks:
 
Reported: 2009-08-06 15:16 UTC by Martin Entlicher
Modified: 2009-08-07 17:58 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter: 144032


Attachments
stacktrace (3.68 KB, text/plain)
2009-08-06 15:16 UTC, Martin Entlicher
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Entlicher 2009-08-06 15:16:16 UTC
Build: NetBeans IDE Dev (Build 090803)
VM: Java HotSpot(TM) Client VM, 14.1-b02, Java(TM) SE Runtime Environment, 1.6.0_15-b03
OS: Linux, 2.6.22-14-generic, i386

User Comments:
GUEST: Added a number of --cp:p arguments to add saxonsa9 jars to the classpath. Started NetBeans.



Stacktrace: 
java.lang.NoClassDefFoundError: Could not initialize class org.netbeans.modules.ant.freeform.spi.support.Util
        at org.netbeans.modules.ant.freeform.FreeformProject.getPrimaryConfigurationData(FreeformProject.java:108)
        at org.netbeans.modules.ant.freeform.FreeformEvaluator.initEval(FreeformEvaluator.java:107)
        at org.netbeans.modules.ant.freeform.FreeformEvaluator.init(FreeformEvaluator.java:85)
        at org.netbeans.modules.ant.freeform.FreeformEvaluator.<init>(FreeformEvaluator.java:80)
        at org.netbeans.modules.ant.freeform.FreeformProject.<init>(FreeformProject.java:95)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(NativeConstructorAccessorImpl.java:0)
Comment 1 Martin Entlicher 2009-08-06 15:16:21 UTC
Created attachment 85915 [details]
stacktrace
Comment 2 Jesse Glick 2009-08-07 00:46:19 UTC
Root exception is:

org.xml.sax.SAXParseException: s4s-att-not-allowed: Attribute 'name' cannot appear in element 'element'.
	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:195)
	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.java:131)
	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:384)
	at com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.reportSchemaErr(XSDHandler.java:2537)
	at com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.reportSchemaError(XSDHandler.java:2528)
	at com.sun.org.apache.xerces.internal.impl.xs.traversers.XSAttributeChecker.reportSchemaError(XSAttributeChecker.java:1623)
	at com.sun.org.apache.xerces.internal.impl.xs.traversers.XSAttributeChecker.checkAttributes(XSAttributeChecker.java:1140)
	at com.sun.org.apache.xerces.internal.impl.xs.traversers.XSAttributeChecker.checkAttributes(XSAttributeChecker.java:996)
	at com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDElementTraverser.traverseGlobal(XSDElementTraverser.java:213)
	at com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.traverseSchemas(XSDHandler.java:1258)
	at com.sun.org.apache.xerces.internal.impl.xs.traversers.XSDHandler.parseSchema(XSDHandler.java:579)
	at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadSchema(XMLSchemaLoader.java:552)
	at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadGrammar(XMLSchemaLoader.java:519)
	at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaLoader.loadGrammar(XMLSchemaLoader.java:485)
	at com.sun.org.apache.xerces.internal.jaxp.validation.XMLSchemaFactory.newSchema(XMLSchemaFactory.java:210)
	at javax.xml.validation.SchemaFactory.newSchema(SchemaFactory.java:594)
	at javax.xml.validation.SchemaFactory.newSchema(SchemaFactory.java:626)
	at org.netbeans.modules.ant.freeform.spi.support.Util.<clinit>(Util.java:389)

So freeform-project-general.xsd cannot be parsed. Some sort of problem with Xerces, I guess, though I cannot guess what
- you do not appear to have an extra copy in your bootcp.

No idea how to reproduce. Recent exception possibly related to ergonomics (but not the 6.5 version). I can however

1. Only try to parse these XML schemas if and when you actually try to change project.xml through the GUI. (Better for
project open time anyway.)

2. Make a failure to parse them nonfatal - exception reporter will be notified but will be written to disk as /1.

core-main #b2208ef6a4df
Comment 3 Jesse Glick 2009-08-07 00:46:53 UTC
*** Issue 169992 has been marked as a duplicate of this issue. ***
Comment 4 Quality Engineering 2009-08-07 17:58:03 UTC
Integrated into 'main-golden', will be available in build *200908071401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/b2208ef6a4df
User: Jesse Glick <jglick@netbeans.org>
Log: #169994: unreproducible failure to parse schemas. Robustness fix only.