psiegman / epublib

a java library for reading and writing epub files
http://www.siegmann.nl/epublib
1.05k stars 316 forks source link

failure at book reading #3

Closed rsaccon closed 13 years ago

rsaccon commented 13 years ago

I tried to read several epub books, and in most cases it worked, but reading the RobinsonCrusoe.epub failed, below the stacktrace:

java.lang.RuntimeException: remote resource is not cached : [http://openebook.org/dtds/oeb-1.2/oebpkg12.dtd] cannot continue
    at nl.siegmann.epublib.epub.EpubProcessor$1.resolveEntity(EpubProcessor.java:49)
    at com.sun.org.apache.xerces.internal.util.EntityResolverWrapper.resolveEntity(EntityResolverWrapper.java:107)
    at com.sun.org.apache.xerces.internal.impl.XMLEntityManager.resolveEntityAsPerStax(XMLEntityManager.java:1018)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$DTDDriver.dispatch(XMLDocumentScannerImpl.java:1192)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$DTDDriver.next(XMLDocumentScannerImpl.java:1090)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(XMLDocumentScannerImpl.java:1003)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:648)
    at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:140)
    at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:511)
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:808)
    at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:737)
    at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:119)
    at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:235)
    at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:284)
    at nl.siegmann.epublib.util.ResourceUtil.getAsDocument(ResourceUtil.java:192)
    at nl.siegmann.epublib.util.ResourceUtil.getAsDocument(ResourceUtil.java:172)
    at nl.siegmann.epublib.epub.PackageDocumentReader.read(PackageDocumentReader.java:50)
    at nl.siegmann.epublib.epub.EpubReader.processPackageResource(EpubReader.java:79)
    at nl.siegmann.epublib.epub.EpubReader.readEpub(EpubReader.java:64)
    at nl.siegmann.epublib.epub.EpubReader.readEpub(EpubReader.java:56)
    at nl.siegmann.epublib.epub.EpubReader.readEpub(EpubReader.java:47)

With Bookworm online reader I could open it.

I tried other versions found online of Robinson Crusoe, and I could successfully open them with epublib, so the problem might be rather with that particular ebook than with epubllib.

psiegman commented 13 years ago

Can you send me a link to this book ?

rsaccon commented 13 years ago

Hi, I don't remember from where I downloaded it, so I put it in my dropbox:

http://dl.dropbox.com/u/10540192/RobinsonCrusoe.epub

psiegman commented 13 years ago

added the missing dtds. Should work now.

psiegman commented 13 years ago

Cool that most books work though :)