![]() |
#1 |
Zealot
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 106
Karma: 52102
Join Date: Jun 2010
Device: Samsung Android Tablet w/Moon+ Pro Reader
|
Error: CSSNamespaceRule: namespaceURI is readonly
I'm getting an error that I've never seen before when converting a .htmlz file to epub (or any other format for that matter).
1) this file started as a badly formatted regular html file that was a conversion from abcamberlit converter, with several dozen images and lots of text. 2) I imported that file.html into calibre with no error, it came in as a .zip file 3) I used calibre to convert the .zip to .htmlz, again no error at all 4) I spent about 12 hours editing the file, cleaning up formatting, adding a few css classes, searching and replacing some here and there but nothing different than I've done hundreds of times on other files before ...then upon converting the edited .htmlz to epub (or any other format), I get the following error and cannot continue: Code:
calibre, version 0.8.16 ERROR: Conversion Error: ... <snip> Flattening CSS and remapping font sizes... Python function terminated unexpectedly CSSNamespaceRule: namespaceURI is readonly. (Error Code: 1) Traceback (most recent call last): File "site.py", line 132, in main File "site.py", line 109, in run_entry_point File "site-packages\calibre\utils\ipc\worker.py", line 181, in main File "site-packages\calibre\gui2\convert\gui_conversion.py", line 31, in gui_convert_override File "site-packages\calibre\gui2\convert\gui_conversion.py", line 25, in gui_convert File "site-packages\calibre\ebooks\conversion\plumber.py", line 1023, in run File "site-packages\calibre\ebooks\oeb\transforms\flatcss.py", line 123, in __call__ File "site-packages\calibre\ebooks\oeb\transforms\flatcss.py", line 150, in stylize_spine File "site-packages\calibre\ebooks\oeb\stylizer.py", line 222, in __init__ File "site-packages\cssutils-0.9.7b4-py2.7.egg\cssutils\util.py", line 719, in __setitem__ File "site-packages\cssutils-0.9.7b4-py2.7.egg\cssutils\css\cssnamespacerule.py", line 235, in _setNamespaceURI File "site-packages\cssutils-0.9.7b4-py2.7.egg\cssutils\errorhandler.py", line 96, in __handle xml.dom.NoModificationAllowedErr: CSSNamespaceRule: namespaceURI is readonly. It displays perfectly in firefox and IE8, I can't see anything wrong with it. Can anyone please help me to salvage this? I've invested *way* too much time in this particular file to start over! Thanks The REAL Joe |
![]() |
![]() |
![]() |
#2 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,307
Karma: 27111242
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
post the css that error message isn't enough information.
|
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Zealot
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 106
Karma: 52102
Join Date: Jun 2010
Device: Samsung Android Tablet w/Moon+ Pro Reader
|
css is embedded in the html file, here it is
Code:
<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <style type="text/css"> @namespace h "http: //www.w3.org/1999/xhtml"; .calibre { display: block; margin-bottom: 0; margin-left: 6pt; margin-right: 6pt; margin-top: 0; padding-left: 0; padding-right: 0 } .calibre1 { display: block; text-align: center } .calibre10 { height: 209px; width: 223px } .calibre11 { height: 86px; width: 87px } .calibre12 { height: 11px; width: 39px } .calibre13 { height: 114px; width: 169px } .calibre14 { height: 40px; width: 115px } .calibre15 { height: 84px; width: 84px } .calibre16 { height: 101px; width: 233px } .calibre17 { height: 108px; width: 107px } .calibre18 { height: 500px; width: 378px } .calibre19 { height: 205px; width: 291px } .calibre2 { color: blue; cursor: pointer; text-decoration: underline } .calibre20 { height: 500px; width: 368px } .calibre21 { height: 449px; width: 336px } .calibre22 { height: 92px; width: 243px } .calibre23 { height: 94px; width: 100px } .calibre24 { height: 94px; width: 93px } .calibre25 { display: block; list-style-position: outside; list-style-type: decimal; margin-bottom: 0; margin-left: 48px; margin-right: 0; margin-top: 0; padding-bottom: 0; padding-left: 0; padding-right: 0; padding-top: 0; text-align: left; text-indent: 0 } .calibre26 { display: list-item } .calibre27 { height: 449px; width: 335px } .calibre28 { height: 93px; width: 93px } .calibre29 { height: 500px; width: 346px } .calibre3 { border: 1px inset; color: #000; display: block; height: 2px; margin-bottom: 0.5em; margin-left: auto; margin-right: auto; margin-top: 0.5em } .calibre30 { height: 387px; width: 284px } .calibre31 { height: 156px; width: 334px } .calibre32 { height: 145px; width: 253px } .calibre33 { height: 123px; width: 243px } .calibre34 { height: 123px; width: 244px } .calibre35 { height: 275px; width: 280px } .calibre36 { height: 276px; width: 280px } .calibre37 { height: 189px; width: 189px } .calibre38 { height: 150px; width: 127px } .calibre39 { height: 228px; width: 163px } .calibre4 { display: block } .calibre40 { height: 228px; width: 161px } .calibre41 { height: 124px; width: 124px } .calibre42 { height: 115px; width: 170px } .calibre43 { height: 459px; width: 328px } .calibre44 { height: 115px; width: 169px } .calibre45 { height: 41px; width: 43px } .calibre46 { height: 237px; width: 135px } .calibre47 { height: 163px; width: 175px } .calibre48 { height: 44px; width: 78px } .calibre49 { height: 263px; width: 176px } .calibre5 { display: block; margin-bottom: 0; margin-left: 0; margin-right: 0; margin-top: 0; text-align: justify; text-indent: 1.5em } .calibre50 { height: 11px; width: 43px } .calibre51 { height: 264px; width: 177px } .calibre52 { height: 495px; width: 181px } .calibre53 { border: 1px inset; border-style: solid none none none; color: #000; display: block; height: 2px; margin-bottom: 0.5em; margin-left: auto; margin-right: auto; margin-top: 0.5em } .calibre54 { display: block; list-style-position: outside; list-style-type: disc; margin-bottom: 0; margin-left: 48px; margin-right: 0; margin-top: 0; padding-bottom: 0; padding-left: 0; padding-right: 0; padding-top: 0; text-align: left; text-indent: 0 } .calibre55 { height: 130px; width: 203px } .calibre56 { height: 500px; width: 345px } .calibre57 { height: 215px; width: 161px } .calibre58 { height: 216px; width: 154px } .calibre59 { height: 105px; width: 187px } .calibre6 { height: 56px; width: 41px } .calibre60 { height: 103px; width: 162px } .calibre61 { height: 218px; width: 334px } .calibre62 { height: 247px; width: 334px } .calibre63 { height: 172px; width: 285px } .calibre64 { height: 107px; width: 107px } .calibre65 { height: 223px; width: 288px } .calibre66 { height: 392px; width: 273px } .calibre67 { height: 231px; width: 320px } .calibre68 { height: 279px; width: 278px } .calibre69 { height: 200px; width: 151px } .calibre7 { height: 500px; width: 344px } .calibre70 { height: 273px; width: 291px } .calibre71 { height: 266px; width: 334px } .calibre72 { height: 232px; width: 312px } .calibre73 { border-collapse: separate; border-spacing: 2px; color: #000; display: table; font-family: "Courier New"; font-size: 1em; font-style: normal; font-weight: normal; margin-bottom: 0; margin-top: 0; text-decoration: none; text-indent: 0 } .calibre74 { display: table-row; vertical-align: middle } .calibre75 { display: table-cell; padding-bottom: 1px; padding-left: 1px; padding-right: 1px; padding-top: 1px; text-align: inherit; vertical-align: inherit } .calibre76 { height: 101px; width: 157px } .calibre77 { height: 261px; width: 288px } .calibre78 { height: 496px; width: 257px } .calibre79 { height: 265px; width: 260px } .calibre8 { height: 38px; width: 28px } .calibre80 { height: 143px; width: 320px } .calibre81 { height: 105px; width: 225px } .calibre82 { height: 222px; width: 261px } .calibre83 { height: 276px; width: 295px } .calibre84 { height: 183px; width: 286px } .calibre85 { height: 187px; width: 275px } .calibre86 { height: 168px; width: 333px } .calibre87 { height: 231px; width: 211px } .calibre88 { height: 224px; width: 288px } .calibre89 { height: 16px; width: 187px } .calibre9 { height: 275px; width: 370px } .images { display: block; margin-bottom: 0; margin-left: 0; margin-right: 0; margin-top: 0; text-align: center } .normalpara1 { display: block; margin-bottom: 0; margin-left: 0; margin-right: 0; margin-top: 0; text-align: justify; text-indent: 1.5em } .chapter { display: block; font-weight: bold; font-size: 1.5em; margin-bottom: 2em; margin-left: 0; margin-right: 0; margin-top: 1em; text-align: center; text-indent: 0em } .part { display: block; font-weight: bold; font-size: 1.67em; margin-bottom: 0em; margin-left: 0; margin-right: 0; margin-top: 1em; text-align: center; text-indent: 0em } .center1 { display: block; margin-bottom: 1em; margin-left: 0; margin-right: 0; margin-top: 1em; text-align: center; text-indent: 0em } .quote { display: block; margin-bottom: 1em; margin-left: 7%; margin-right: 7%; margin-top: 1em; text-align: justify; text-indent: 0em } .noindent { display: block; margin-bottom: 0em; margin-left: 0; margin-right: 0; margin-top: 1em; text-align: justify; text-indent: 0em } .copyright1 { display: block; font-size: 0.75em; margin-bottom: 1em; margin-left: 0; margin-right: 0; margin-top: 1em; text-align: center; text-indent: 0em } .copyright2 { display: block; font-size: 0.75em; margin-bottom: 1em; margin-left: 0; margin-right: 0; margin-top: 1em; text-align: center; text-indent: 0em } .scenebreak { display: block; margin-bottom: 0em; margin-left: 0; margin-right: 0; margin-top: 2em; text-align: justify; text-indent: 0em } .subchapter { display: block; font-style: italic; margin-bottom: 0em; margin-left: 0; margin-right: 0; margin-top: 0em; text-align: left; text-indent: 0em } .mbppagebreak { page-break-before: always } </style> <title></title> </head> <body> |
![]() |
![]() |
![]() |
#4 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,307
Karma: 27111242
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
delete the @namespace line you've got a space between http: and //
|
![]() |
![]() |
![]() |
#5 |
Zealot
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 106
Karma: 52102
Join Date: Jun 2010
Device: Samsung Android Tablet w/Moon+ Pro Reader
|
Thank you Kovid, you are a superstar.
I think I inadvertently fubar'd it when searching and replacing for ":" because I had instances where in the text the colon didn't have a space behind it like it should. I'm normally very careful about not running search/replace till I'm within the body of the html code, and with wraparound turned off, but I must have missed it this time. Thanks again for the help! Cheers The REAL Joe |
![]() |
![]() |
Advert | |
|
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
calibre, version 0.8.8 ERROR: Error: Error communicating with device no such column: | e-bookuser | Devices | 1 | 07-03-2011 04:09 PM |
Headless server on NAS readonly problem | artifact | Related Tools | 1 | 06-28-2011 09:34 PM |
error message: ERROR ITMS-4099: "Invalid ISBN: [#] at Book (MZItmspBookPac | NewDay | ePub | 3 | 10-07-2010 01:47 PM |
ERROR: Error: Error communicating with device | JWood | Calibre | 10 | 04-20-2010 07:28 PM |
Readonly Database | seanbw | Calibre | 6 | 03-17-2010 06:30 PM |