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 46048

Summary: Exception when opened html project
Product: projects Reporter: Martin Grebac <mgrebac>
Component: AntAssignee: Jesse Glick <jglick>
Status: CLOSED FIXED    
Severity: blocker    
Priority: P3    
Version: 4.x   
Hardware: PC   
OS: Linux   
Issue Type: DEFECT Exception Reporter:
Bug Depends on:    
Bug Blocks: 41535    

Description Martin Grebac 2004-07-12 16:01:59 UTC
Got this exception after I opened html project,
but there doesn't seem anything wrong with it, so
some other project may be causing problems. It
would be good to know at least which one causes
the problem (I usually have about 40-60 projects
opened).

java.lang.AssertionError
org.netbeans.spi.project.support.ant.AntProjectHelper.getConfigurationDataRoot(AntProjectHelper.java:262)
org.netbeans.spi.project.support.ant.AntProjectHelper.getConfigurationFragment(AntProjectHelper.java:561)
org.netbeans.spi.project.support.ant.ExtensibleMetadataProviderImpl.getConfigurationFragment(ExtensibleMetadataProviderImpl.java:48)
org.netbeans.modules.ant.freeform.SourceLevelQueryImpl.getSourceLevel(SourceLevelQueryImpl.java:57)
org.netbeans.modules.java.project.ProjectSourceLevelQueryImpl.getSourceLevel(ProjectSourceLevelQueryImpl.java:37)
org.netbeans.api.java.queries.SourceLevelQuery.getSourceLevel(SourceLevelQuery.java:46)
org.netbeans.modules.javacore.JMManager.getSourceLevel(JMManager.java:852)
org.netbeans.modules.javacore.JMManager.getRootURI(JMManager.java:858)
org.netbeans.modules.javacore.JMManager.resolveCPRoot(JMManager.java:776)
org.netbeans.modules.javacore.JMManager.resolveCodebases(JMManager.java:662)
org.netbeans.modules.javacore.JMManager$1.run(JMManager.java:624)
org.openide.util.Task.run(Task.java:136)
org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:330)
[catch] at
org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:686)
Comment 1 Jesse Glick 2004-07-12 21:41:20 UTC
Yes, some freeform project has a corrupt or missing project.xml. But
APH fails to deal with the problem gracefully. I know about it.
Comment 2 Jesse Glick 2004-07-13 02:53:26 UTC
Have working patch & unit test. Parse errors in project.xml should now
be reported to the log file (annotated with the file name
responsible), but project loading should continue (and any
programmatic changes to project.xml via APH should write out
well-formed XML data). Of course in such a case the project data will
probably be missing critical information and so further project
operations may give other errors. I am not sure how the problem
happened in your case since a fatal parse error in the XML should have
prevented the project from being loaded to begin with; perhaps the
parse error was introduced after it was loaded?
Comment 3 Jesse Glick 2004-07-14 22:39:37 UTC
committed   * Up-To-Date  1.3        
ant/project/src/org/netbeans/modules/project/ant/AntBasedProjectFactorySingleton.java
committed   * Up-To-Date  1.4        
ant/project/src/org/netbeans/modules/project/ant/Util.java
committed   * Up-To-Date  1.20       
ant/project/src/org/netbeans/spi/project/support/ant/AntProjectHelper.java
committed   * Up-To-Date  1.10       
ant/project/test/unit/src/org/netbeans/spi/project/support/ant/AntBasedTestUtil.java
committed   * Up-To-Date  1.13       
ant/project/test/unit/src/org/netbeans/spi/project/support/ant/AntProjectHelperTest.java
Comment 4 Martin Grebac 2005-03-18 12:22:33 UTC
didn't happen again