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 127117 - org.xml.sax.SAXParseException: Premature end of file.
Summary: org.xml.sax.SAXParseException: Premature end of file.
Status: VERIFIED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: -- Other -- (show other bugs)
Version: 6.x
Hardware: All All
: P1 blocker (vote)
Assignee: Jiri Skrivanek
URL: http://statistics.netbeans.org/except...
Keywords: RANDOM
: 168429 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-02-11 12:43 UTC by Jiri Skrivanek
Modified: 2009-11-04 07:12 UTC (History)
25 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 1017


Attachments
stacktrace (6.23 KB, text/plain)
2008-02-11 12:43 UTC, Jiri Skrivanek
Details
stacktrace (6.14 KB, text/plain)
2008-02-11 16:28 UTC, Michael Nazarov
Details
stacktrace (6.23 KB, text/plain)
2008-02-14 15:49 UTC, Michael Nazarov
Details
stacktrace (2.31 KB, text/plain)
2008-02-15 16:07 UTC, rodrigorsantos
Details
stacktrace (6.14 KB, text/plain)
2008-02-21 08:00 UTC, Marian Mirilovic
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Skrivanek 2008-02-11 12:43:38 UTC
Build: NetBeans IDE Dev (Build 20080211093816)
VM: Java HotSpot(TM) Client VM, 10.0-b19
OS: Windows XP, 5.1, x86

User Comments: 
I did:

- open the Open Project dialog
- select main/ant.browsetask and exception was thrown
Comment 1 Jiri Skrivanek 2008-02-11 12:43:44 UTC
Created attachment 56434 [details]
stacktrace
Comment 2 Lukas Hasik 2008-02-11 13:22:38 UTC
this issue has more than 40 duplicates
Jirko, is it reproducible? 

org.xml.sax.SAXParseException: Premature end of file.
        at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1231)
        at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:522)
        at org.netbeans.core.xml.FileEntityResolver$DTDParser.parse(FileEntityResolver.java:430)
        at org.netbeans.core.xml.FileEntityResolver.getEnvForIDO(FileEntityResolver.java:171)
        at org.netbeans.core.xml.FileEntityResolver.getEnvironment(FileEntityResolver.java:164)
        at org.openide.loaders.Environment.findForOne(Environment.java:132)
        at org.openide.loaders.InstanceDataObject.getCookiesLookup(InstanceDataObject.java:603)
Comment 3 Jiri Skrivanek 2008-02-11 14:31:52 UTC
No, it is probably random.
Comment 4 Michael Nazarov 2008-02-11 16:28:36 UTC
Build: NetBeans IDE Dev (Build 200802110004)
VM: Java HotSpot(TM) Client VM, 10.0-b19
OS: Windows XP, 5.1, x86

User Comments: 
Just started IDE.
Comment 5 Michael Nazarov 2008-02-11 16:28:39 UTC
Created attachment 56470 [details]
stacktrace
Comment 6 Michael Nazarov 2008-02-14 15:49:45 UTC
Build: NetBeans IDE Dev (Build 200802140010)
VM: Java HotSpot(TM) Client VM, 10.0-b19
OS: Windows XP, 5.1, x86

User Comments: 
Just started IDE.
Comment 7 Michael Nazarov 2008-02-14 15:49:56 UTC
Created attachment 56689 [details]
stacktrace
Comment 8 Exceptions Reporter 2008-02-15 00:58:20 UTC
THIS ISSUE HAS ALREADY 50 DUPLICATES
Comment 9 rodrigorsantos 2008-02-15 16:07:01 UTC
Build: NetBeans IDE 6.0 (Build 200711261600)
VM: Java HotSpot(TM) Client VM, 1.6.0_03-b05
OS: Windows 2000, 5.0, x86

User Comments: 
Comment 10 rodrigorsantos 2008-02-15 16:07:09 UTC
Created attachment 56741 [details]
stacktrace
Comment 11 Marian Mirilovic 2008-02-21 08:00:35 UTC
Build: NetBeans IDE Dev (Build 200802140010)
VM: Java HotSpot(TM) Client VM, 10.0-b19
OS: Linux, 2.6.12-10-686, i386

User Comments: 
I started IDE for the first time with new Userdir
Comment 12 Marian Mirilovic 2008-02-21 08:00:58 UTC
Created attachment 56964 [details]
stacktrace
Comment 13 Marian Mirilovic 2008-02-21 08:07:01 UTC
64 duplicates so far ....
Comment 14 Lukas Hasik 2008-02-21 09:16:40 UTC
Jardo, could you please look at it? It seems that it happens even with new installation with a fresh userdir. 
Are we able to find out the cause from the stacktraces? 
Comment 15 Exceptions Reporter 2008-03-20 08:47:55 UTC
This issue has already 100 duplicates 
Comment 16 Marian Mirilovic 2008-03-20 09:13:41 UTC
kcundick:  	Running through the tutorial at http://www.netbeans.org/kb/60/websvc/jax-ws.html, had been in the middle of
creating the tutorial project.
kcundick: 	Creating new webservice based on tutorial at http://www.netbeans.org/kb/60/websvc/jax-ws.html, under Creating
a Web Service from a Java Class, step 2.
kcundick: 	Building web services client from tutorial found here: http://www.netbeans.org/kb/60/websvc/jax-ws.html,
Client 2: Servlet in Web Application; Step 1.

kcundick, are you able to reproduce it with fresh userdir ?
Comment 17 Jaroslav Tulach 2008-03-20 14:58:34 UTC
The exceptions are unlikely duplicates, each of them is probably for different file on disk. The info about which file 
is corrupted is sent to each log file and can be accessed via the gesture collector. 

For example the stack that goes from:
org.netbeans.modules.editor.mimelookup.impl.CompoundFolderChildren.rebuild(CompoundFolderChildren.java:167)
means that there is some file inside Editors/ that is broken.

I have added better logging, I do not think I can do anything else.


changeset:   74443:c8d509bc2442
tag:         tip
parent:      74441:efb2032d1b64
parent:      74442:7dfa7ddbf28e
user:        Jaroslav Tulach <jtulach@netbeans.org>
date:        Thu Mar 20 13:55:30 2008 +0100
summary:     Merge: #127117: Print out which file is corrupted when the parsing fails
Comment 18 dheffelfinger 2008-04-01 14:27:07 UTC
This stacktrace shows up on each and every single nightly. It comes up as soon as NetBeans is opened, and it comes up
pretty much every time a file is clicked from the project window. 

I suspected this was put in on purpose to discourage using nightlies for "real work", since the issue was there before
6.1 beta, but disappeared just for the beta. Then reappeared on later nightlies.

It makes the 6.1 nightly builds unusable, it is very hard to look for other bugs when a pop up warning about an
IOException is popping up every five seconds.

At least on Linux 64 bit this issue is not hard to reproduce at all.
Comment 19 Lukas Hasik 2008-04-01 15:00:37 UTC
dheffelfinger, could you attach you messages.log file?
Comment 20 Marian Mirilovic 2008-04-01 22:07:28 UTC
java.io.IOException: Parsing MultiFileObject@a331d3[Editors/text/javascript/Settings.settings]: Premature end of file.
http://statistics.netbeans.org/analytics/detail.do?id=41192

java.io.IOException: Parsing MultiFileObject@4811a6da[Windows2Local/Components/CommonPalette.settings]: Premature end of
file.
http://statistics.netbeans.org/analytics/detail.do?id=42413
Comment 21 Jaroslav Tulach 2008-04-02 12:34:13 UTC
Also attach content of Editors/text/javascript/Settings.settings and other files that cause the failure.
Comment 22 rmatous 2008-04-03 14:18:47 UTC
I haven't seen it yet, many possible causes, the best would be to be able to reproduce. No idea how to find the cause.
Comment 23 rmatous 2008-04-03 16:40:12 UTC
I haven't seen it yet, many possible causes, the best would be to be able to reproduce. No idea how to find the cause.
Comment 24 Antonin Nebuzelsky 2008-04-15 17:16:03 UTC
Reassigning to new module owner jskrivanek.
Comment 25 Lukas Hasik 2008-04-17 11:31:05 UTC
the issue has 152 duplicates. Marking as candidate for 61 patch1 
Comment 26 Jiri Skrivanek 2008-04-23 12:04:09 UTC
I can't reproduce this issue anymore. Lastly reported exception is from build 080406. Without steps to reproduce or
offending *.settings file we can't investigate what is the cause.
Comment 27 Jiri Skrivanek 2008-04-29 07:57:34 UTC
As stated in my previous post, without being able to reproduce this issue we can't fix it. Feel free to reopen if you
will face this issue in latest builds.
Comment 28 Jiri Skrivanek 2008-04-29 07:57:54 UTC
Verified.
Comment 29 William Leonard 2009-02-04 15:13:27 UTC
This bug is still occurring (and has been reported hundreds of times) since it was closed last April. I'm re-opening for
additional evaluation.
Comment 30 Jiri Skrivanek 2009-02-05 10:21:27 UTC
I added content of file to error message. But still it would be helpful to write-down steps to reproduce or attach
offending file.
Comment 31 William Leonard 2009-02-05 15:33:40 UTC
This exception occurs every time I start NetBeans. I think it has to do with the fact that I have a file open in the
editor that no longer exists on disk. What additional information can I provide for you?
Comment 32 Quality Engineering 2009-02-06 07:50:53 UTC
Integrated into 'main-golden', will be available in build *200902060201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/cdf7482c9a68
User: Jiri Skrivanek <jskrivanek@netbeans.org>
Log: #127117 - print content of file in case of error.
Comment 33 Jiri Skrivanek 2009-02-25 08:11:30 UTC
Fixed. IOExceptions are ignored for Windows2Local files because they are harmless. Files can be corrupted if their
saving is interrupted but windows system can recover from this.

http://hg.netbeans.org/core-main/rev/ba1368ccf36e
Comment 34 Quality Engineering 2009-02-25 19:48:50 UTC
Integrated into 'main-golden', will be available in build *200902251401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/ba1368ccf36e
User: Jiri Skrivanek <jskrivanek@netbeans.org>
Log: #127117 - ignore failures for Windows2Local because they are harmless. Files can be corrupted if their saving is interrupted but windows system can recover from this.
Comment 35 Jiri Skrivanek 2009-03-06 09:59:18 UTC
Verified.
Comment 36 Jiri Skrivanek 2009-07-13 13:10:22 UTC
*** Issue 168429 has been marked as a duplicate of this issue. ***