'Premature end of file' error when indexing

473 views
Skip to first unread message

energylibrarian

unread,
Nov 16, 2011, 11:28:41 PM11/16/11
to XTF Users List
Hi,

I'm currently implementing XTF, and when I try to add new PDFs, I get
an error statement:

XML Parser Exception: class net.sf.saxon.trans.dynamicError
With message: org.xml.sax.SAXParseException: Premature end of file.

I am following the tutorial exactly. Does anyone have any idea how to
fix this?

Thanks!

Seth.Public

unread,
Nov 17, 2011, 12:24:20 PM11/17/11
to xtf-...@googlegroups.com
I am guessing that your pdfs are not created to standards. Is there any way you can recompile one with another program to verify?


--
You received this message because you are subscribed to the Google Groups "XTF Users List" group.
To post to this group, send email to xtf-...@googlegroups.com.
To unsubscribe from this group, send email to xtf-user+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/xtf-user?hl=en.


Martin Haye

unread,
Nov 17, 2011, 12:25:40 PM11/17/11
to xtf-...@googlegroups.com
I think there may be a missing XML end-tag in one of your stylesheets or other XML documents. Is there a more detailed call stack in the Tomcat log? That would help narrow it down.

--Martin


From: xtf-...@googlegroups.com [xtf-...@googlegroups.com] on behalf of Seth.Public [seth....@gmail.com]
Sent: Thursday, November 17, 2011 9:24 AM
To: xtf-...@googlegroups.com
Subject: Re: [xtf-user] 'Premature end of file' error when indexing

Bewley, John

unread,
Nov 17, 2011, 12:48:22 PM11/17/11
to xtf-...@googlegroups.com

I had a similar problem while using Adobe Acrobat version 9. I had to go into Document and then Examine document. The left hand pane would show any metadata that had automatically been attached. Once I deleted those the file would work in XTF. I have not tried anything with version 10 but they have changed the menu items.

 

--

John Bewley

Associate Librarian/Archivist

Music Library

University at Buffalo

716 645 0614

Talia Mathews

unread,
Nov 17, 2011, 2:56:56 PM11/17/11
to xtf-...@googlegroups.com

It says:

Indexing new/updated documents:
Index: "default"
Scanning data directories...
(10%) Indexing [pdf/filename/filename.pdf]...
***PDFtoXML.convert<>Exception: class java.lang.NullPointerException
With message: Null
Saxon error on line 3 column 1 of file (filename; it is a path to the pdf):: SXXP0003:Error reported by XML parser: premature end of file.
Skipping due to errors
***XML parser exception: class net.sf.saxon.trans.DynamicError
with message: org.xml.sax.SAXParseException: Premature end of file.
File: pdf/filename/filename.pdf Done.

It repeats this for every PDF I add. Any insight would be greatly appreciated! Thanks.


________________________________________
From: xtf-...@googlegroups.com [xtf-...@googlegroups.com] On Behalf Of Martin Haye [R.C.Mar...@ucop.edu]
Sent: Thursday, November 17, 2011 9:25 AM
To: xtf-...@googlegroups.com
Subject: RE: [xtf-user] 'Premature end of file' error when indexing

energylibrarian

unread,
Nov 19, 2011, 2:24:26 PM11/19/11
to xtf-...@googlegroups.com
To follow up: the problem turned out to be that our PDFs were optimized for web viewing by Adobe Acrobat. After turning off the web optimization feature, opening, and resaving, the problem was fixed. 
Reply all
Reply to author
Forward
0 new messages