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 29579 - DOMConventor.delegateRead has to search a proper child
Summary: DOMConventor.delegateRead has to search a proper child
Status: VERIFIED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: -- Other -- (show other bugs)
Version: 3.x
Hardware: All All
: P1 blocker (vote)
Assignee: David Konecny
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-12-16 17:43 UTC by Ondrej Rypacek
Modified: 2008-12-22 18:55 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
settings with serialized ProjectMember (1.12 KB, text/plain)
2003-03-18 12:29 UTC, Ondrej Rypacek
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ondrej Rypacek 2002-12-16 17:43:50 UTC
When using DOMConvertor.delegateRead on Element
that contains stored projectMember (previously
written by delegateWrite) the following exception
is thrown:
java.io.IOException: Expected CDATA block: 
          
	at
org.netbeans.spi.settings.DOMConvertor.delegateRead(DOMConvertor.java:178)
	at
org.netbeans.spi.jarpackager.MyConvertor.appendDelegateRead(MyConvertor.java:166)
	at
org.netbeans.spi.jarpackager.ContentDescriptorInput$Convertor.readElement(ContentDescriptorInput.java:169)
	at
org.netbeans.spi.settings.DOMConvertor.delegateRead(DOMConvertor.java:183)
	at
org.netbeans.spi.jarpackager.MyConvertor.appendDelegateReadCollection(MyConvertor.java:230)
	at
org.netbeans.spi.jarpackager.JarContentImpl$Convertor.readElement(JarContentImpl.java:337)
	at
org.netbeans.spi.settings.DOMConvertor.read(DOMConvertor.java:89)
	at
org.netbeans.modules.settings.InstanceProvider$InstanceCookieImpl.instanceCreate(InstanceProvider.java:254)
	at
org.netbeans.core.naming.Utils.instanceCreate(Utils.java:105)
	at
org.netbeans.core.naming.Utils.getObjectForFile(Utils.java:92)
	at
org.netbeans.core.naming.DOContext.lookupImpl(DOContext.java:140)
	at
org.netbeans.core.naming.DOContext.lookup(DOContext.java:135)
	at
org.netbeans.api.projects.settings.ConfigurationContext.lookup(ConfigurationContext.java:100)
	at
org.netbeans.modules.projects.settings.ProxyContext.lookup(ProxyContext.java:78)
	at
org.netbeans.modules.projects.settings.ProxyContext.lookup(ProxyContext.java:70)
	at
org.netbeans.spi.projects.ContextSettings.getProperty(ContextSettings.java:131)
	at
org.netbeans.modules.jarpackager.JarPackagerImpl$Settings.getContent(JarPackagerImpl.java:190)
	at
org.netbeans.modules.jarpackager.JarPackagerImpl.getContent(JarPackagerImpl.java:151)
	at
org.netbeans.modules.jarpackager.JarTargetLook.getPropertySets(JarTargetLook.java:114)
	at
org.netbeans.spi.looks.ProxyLook.getPropertySets(ProxyLook.java:734)
	at
org.netbeans.spi.looks.ProxyLook.getPropertySets(ProxyLook.java:734)
	at
org.netbeans.spi.looks.ProxyLook.getPropertySets(ProxyLook.java:734)
	at
org.netbeans.spi.looks.ProxyLook.getPropertySets(ProxyLook.java:734)
	at
org.netbeans.spi.looks.ProxyLook.getPropertySets(ProxyLook.java:734)
	at
org.netbeans.api.looks.LookNode.getPropertySets(LookNode.java:828)
	at
org.netbeans.modules.looks.NodeProxyLook.getPropertySets(NodeProxyLook.java:228)
	at
org.netbeans.spi.looks.ProxyLook.getPropertySets(ProxyLook.java:734)
	at
org.netbeans.api.looks.LookNode.getPropertySets(LookNode.java:828)
	at
org.openide.explorer.propertysheet.PropertySheet.setCurrentNode(PropertySheet.java:501)
	at
org.openide.explorer.propertysheet.PropertySheet.access$700(PropertySheet.java:52)
	at
org.openide.explorer.propertysheet.PropertySheet$DelayedUpdater.actionPerformed(PropertySheet.java:251)
	at
javax.swing.Timer.fireActionPerformed(Timer.java:150)
	at javax.swing.Timer$DoPostEvent.run(Timer.java:108)
	at
java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:154)
	at
java.awt.EventQueue.dispatchEvent(EventQueue.java:337)
	at
java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:131)
	at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:98)
	at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
	at
java.awt.EventDispatchThread.run(EventDispatchThread.java:85)



Steps to reproduce:
0) get the latest version of jarpackager from CVS
and build it
1) create a new jarpackager build target
   1a) right-click on Output, select NewJar
   1b) fill in anything into the two fields that
follow
2) setup content to contain something
   2a) click on the created build target node
   2b) in the property editor bellow, click the
JarContent property and click "..." to bring up a
contents editing window
   2c) toggle some item , e.g. Compiled Classes to
true
   2d) click OK to close the dialog
3) close and reopen the project (or whole netbeans
if necessary)
4) click the jarpackager build target to force
deserialization of the settings
Comment 1 Ondrej Rypacek 2002-12-19 10:44:26 UTC
can do without for this moment
Comment 2 Vitezslav Stejskal 2002-12-22 00:46:58 UTC
Ondro, put the PROJECTS keyword to defects filed against
prj40_prototype branch code please. Thanks.
Comment 3 Ondrej Rypacek 2003-03-10 17:37:12 UTC
blocks the development of jar-packager, no workaround
Comment 4 Jan Pokorsky 2003-03-17 15:58:08 UTC
Please attach the .settings file.
Comment 5 Ondrej Rypacek 2003-03-18 12:29:59 UTC
Created attachment 9439 [details]
settings with serialized ProjectMember
Comment 6 Jan Pokorsky 2003-03-18 15:52:23 UTC
DOMConvertor.delegateRead has to skip child nodes other than
Node.CDATA_SECTION_NODE in order to work properly. Otherwise it may fail.
Comment 7 Jan Pokorsky 2003-03-18 15:55:41 UTC
fixed in the trunk

/cvs/core/settings/src/org/netbeans/spi/settings/DOMConvertor.java new
revision: 1.9; previous revision: 1.8
Comment 8 Jan Pokorsky 2003-03-18 16:02:55 UTC
merged to release35

/cvs/core/settings/src/org/netbeans/spi/settings/DOMConvertor.java
new revision: 1.8.2.1; previous revision: 1.8
Comment 9 Ondrej Rypacek 2003-07-08 14:51:28 UTC
yes, it works