You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to convert a Hacker News comment page into epub. I use: pandoc "https://news.ycombinator.com/item?id=30095521" -t epub3 -o hn.epub.
The conversion goes through just fine, but when opened in iBooks (macOS Books.app), it shows an error message:
This page contains the following errors:
error on line 32 at column 58: Attribute style redefined
Below is a rendering of the page up to the first error.
and stops rendering almost right at the beginning.
KOReader reads it just fine, presumably because it ignores the error. I don't have any other epub readers to test with, but attached the file for others to try: hn.epub.zip
The Epub validator (epubcheck) throws the same error as FATAL:
Validating using EPUB version 3.2 rules.
ERROR(RSC-005): hn.epub/EPUB/text/ch001.xhtml(21,113): Error while parsing file: attribute "width" not allowed here; expected attribute "about", "accesskey", "aria-activedescendant", "aria-atomic", "aria-autocomplete", "aria-busy", "aria-checked", "aria-colcount", "aria-colindex", "aria-colspan", "aria-controls", "aria-current", "aria-describedby", "aria-details", "aria-disabled", "aria-dropeffect", "aria-errormessage", "aria-expanded", "aria-flowto", "aria-grabbed", "aria-haspopup", "aria-hidden", "aria-invalid", "aria-keyshortcuts", "aria-label", "aria-labelledby", "aria-level", "aria-live", "aria-modal", "aria-multiline", "aria-multiselectable", "aria-orientation", "aria-owns", "aria-placeholder", "aria-posinset", "aria-pressed", "aria-readonly", "aria-relevant", "aria-required", "aria-roledescription", "aria-rowcount", "aria-rowindex", "aria-rowspan", "aria-selected", "aria-setsize", "aria-sort", "aria-valuemax", "aria-valuemin", "aria-valuenow", "aria-valuetext", "autocapitalize", "autofocus", "border", "class", "content", "contenteditable", "datatype", "dir", "draggable", "epub:type", "hidden", "inlist", "inputmode", "is", "itemid", "itemprop", "itemref", "itemscope", "itemtype", "lang", "nonce", "ns:alphabet", "ns:ph", "onabort", "onauxclick", "onblur", "oncancel", "oncanplay", "oncanplaythrough", "onchange", "onclick", "onclose", "oncontextmenu", "oncopy", "oncuechange", "oncut", "ondblclick", "ondrag", "ondragend", "ondragenter", "ondragleave", "ondragover", "ondragstart", "ondrop", "ondurationchange", "onemptied", "onended", "onerror", "onfocus", "onfocusin", "onfocusout", "onformdata", "oninput", "oninvalid", "onkeydown", "onkeypress", "onkeyup", "onload", "onloadeddata", "onloadedmetadata", "onloadstart", "onmousedown", "onmouseenter", "onmouseleave", "onmousemove", "onmouseout", "onmouseover", "onmouseup", "onpaste", "onpause", "onplay", "onplaying", "onprogress", "onratechange", "onreset", "onresize", "onscroll", "onsecuritypolicyviolation", "onseeked", "onseeking", "onselect", "onslotchange", "onstalled", "onsubmit", "onsuspend", "ontimeupdate", "ontoggle", "ontransitioncancel", "ontransitionend", "ontransitionrun", "ontransitionstart", "onvolumechange", "onwaiting", "onwheel", "prefix", "property", "rel", "resource", "rev", "role", "slot", "spellcheck", "style", "tabindex", "title", "translate", "typeof", "vocab", "xml:base", "xml:lang" or "xml:space" (with xmlns:ns="http://www.w3.org/2001/10/synthesis")
ERROR(RSC-005): hn.epub/EPUB/text/ch001.xhtml(27,126): Error while parsing file: attribute "width" not allowed here; expected attribute "about", "accesskey", "aria-activedescendant", "aria-atomic", "aria-autocomplete", "aria-busy", "aria-checked", "aria-colcount", "aria-colindex", "aria-colspan", "aria-controls", "aria-current", "aria-describedby", "aria-details", "aria-disabled", "aria-dropeffect", "aria-errormessage", "aria-expanded", "aria-flowto", "aria-grabbed", "aria-haspopup", "aria-hidden", "aria-invalid", "aria-keyshortcuts", "aria-label", "aria-labelledby", "aria-level", "aria-live", "aria-modal", "aria-multiline", "aria-multiselectable", "aria-orientation", "aria-owns", "aria-placeholder", "aria-posinset", "aria-pressed", "aria-readonly", "aria-relevant", "aria-required", "aria-roledescription", "aria-rowcount", "aria-rowindex", "aria-rowspan", "aria-selected", "aria-setsize", "aria-sort", "aria-valuemax", "aria-valuemin", "aria-valuenow", "aria-valuetext", "autocapitalize", "autofocus", "border", "class", "content", "contenteditable", "datatype", "dir", "draggable", "epub:type", "hidden", "id", "inlist", "inputmode", "is", "itemid", "itemprop", "itemref", "itemscope", "itemtype", "lang", "nonce", "ns:alphabet", "ns:ph", "onabort", "onauxclick", "onblur", "oncancel", "oncanplay", "oncanplaythrough", "onchange", "onclick", "onclose", "oncontextmenu", "oncopy", "oncuechange", "oncut", "ondblclick", "ondrag", "ondragend", "ondragenter", "ondragleave", "ondragover", "ondragstart", "ondrop", "ondurationchange", "onemptied", "onended", "onerror", "onfocus", "onfocusin", "onfocusout", "onformdata", "oninput", "oninvalid", "onkeydown", "onkeypress", "onkeyup", "onload", "onloadeddata", "onloadedmetadata", "onloadstart", "onmousedown", "onmouseenter", "onmouseleave", "onmousemove", "onmouseout", "onmouseover", "onmouseup", "onpaste", "onpause", "onplay", "onplaying", "onprogress", "onratechange", "onreset", "onresize", "onscroll", "onsecuritypolicyviolation", "onseeked", "onseeking", "onselect", "onslotchange", "onstalled", "onsubmit", "onsuspend", "ontimeupdate", "ontoggle", "ontransitioncancel", "ontransitionend", "ontransitionrun", "ontransitionstart", "onvolumechange", "onwaiting", "onwheel", "prefix", "property", "rel", "resource", "rev", "role", "slot", "spellcheck", "style", "tabindex", "title", "translate", "typeof", "vocab", "xml:base", "xml:lang" or "xml:space" (with xmlns:ns="http://www.w3.org/2001/10/synthesis")
FATAL(RSC-016): hn.epub/EPUB/text/ch001.xhtml(32,38): Fatal Error while parsing file: Attribute "style" was already specified for element "td".
ERROR(RSC-005): hn.epub/EPUB/text/ch001.xhtml(-1,-1): Error while parsing file: Attribute "style" was already specified for element "td".
ERROR(RSC-007): hn.epub/EPUB/text/ch001.xhtml(31,90): Referenced resource "EPUB/text/news" could not be found in the EPUB.
ERROR(RSC-007): hn.epub/EPUB/text/ch001.xhtml(31,132): Referenced resource "EPUB/text/newest" could not be found in the EPUB.
ERROR(RSC-007): hn.epub/EPUB/text/ch001.xhtml(31,158): Referenced resource "EPUB/text/front" could not be found in the EPUB.
ERROR(RSC-007): hn.epub/EPUB/text/ch001.xhtml(31,191): Referenced resource "EPUB/text/newcomments" could not be found in the EPUB.
ERROR(RSC-007): hn.epub/EPUB/text/ch001.xhtml(31,220): Referenced resource "EPUB/text/ask" could not be found in the EPUB.
ERROR(RSC-007): hn.epub/EPUB/text/ch001.xhtml(31,245): Referenced resource "EPUB/text/show" could not be found in the EPUB.
ERROR(RSC-007): hn.epub/EPUB/text/ch001.xhtml(31,271): Referenced resource "EPUB/text/jobs" could not be found in the EPUB.
ERROR(RSC-007): hn.epub/EPUB/text/ch001.xhtml(31,299): Referenced resource "EPUB/text/submit" could not be found in the EPUB.
Check finished with errors
Messages: 1 fatal / 11 errors / 0 warnings / 0 infos
May be related to #3716.
Applies to Epub and Epub3.
Pandoc version?
2.17.0.1 on macOS 12.2
The text was updated successfully, but these errors were encountered:
One of these styles is added by pandoc (for table cell alignment handling), the other comes from the website. Both style definitions must be combined into one to produce valid EPUB.
Explain the problem.
I am trying to convert a Hacker News comment page into epub. I use:
pandoc "https://news.ycombinator.com/item?id=30095521" -t epub3 -o hn.epub
.The conversion goes through just fine, but when opened in iBooks (macOS Books.app), it shows an error message:
and stops rendering almost right at the beginning.
KOReader reads it just fine, presumably because it ignores the error. I don't have any other epub readers to test with, but attached the file for others to try: hn.epub.zip
The Epub validator (epubcheck) throws the same error as
FATAL
:May be related to #3716.
Applies to Epub and Epub3.
Pandoc version?
2.17.0.1 on macOS 12.2
The text was updated successfully, but these errors were encountered: