Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Amazon Kindle > Kindle Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 07-05-2023, 07:05 PM   #1
mg10
Connoisseur
mg10 began at the beginning.
 
Posts: 77
Karma: 10
Join Date: Jul 2013
Device: Kindle Scribe, PW, Kobo Aura One
Error in azw3 books with reduced margins after conversion with Calibre

Hello
I'm not sure if this question should be asked in this forum. If so, please, let me know the best one.
This is a problem that appeared after converting from epub to azw3 with Calibre adding a css entry to reduce left and right margins. This works fine on my Scribe but not on my new PW11 after upgrading it to the latest firmware version.
After the upgrade, started some errors when opening or moving inside the books. If I don't include the code in the css page the converted book works fine but again appear the huge default margins.
The used code is:

html {
margin-left: -45px;
margin-right: -45px
}

And the error that appears in the books:
"An error occurred. If you purchased this item from Amazon, delete the item and download it from the Cloud."

Do you think it's a bug in the new firmware or can the code be modified to fix this behavior?
Thanks
mg10 is offline   Reply With Quote
Old 07-05-2023, 10:51 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,866
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
If the kindle doesnt like negative margins there's nothing calibre can do about it, other than stripping them out.
kovidgoyal is offline   Reply With Quote
Advert
Old 07-06-2023, 07:27 AM   #3
mg10
Connoisseur
mg10 began at the beginning.
 
Posts: 77
Karma: 10
Join Date: Jul 2013
Device: Kindle Scribe, PW, Kobo Aura One
Quote:
Originally Posted by kovidgoyal View Post
If the kindle doesnt like negative margins there's nothing calibre can do about it, other than stripping them out.
Thanks kovidgoyal
It's what I was afraid for... Let's hope this firmware change isn't here to stay...
Thank you for your work with this great tool
mg10 is offline   Reply With Quote
Old 07-06-2023, 08:02 AM   #4
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 74,033
Karma: 129333114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by mg10 View Post
Hello
I'm not sure if this question should be asked in this forum. If so, please, let me know the best one.
This is a problem that appeared after converting from epub to azw3 with Calibre adding a css entry to reduce left and right margins. This works fine on my Scribe but not on my new PW11 after upgrading it to the latest firmware version.
After the upgrade, started some errors when opening or moving inside the books. If I don't include the code in the css page the converted book works fine but again appear the huge default margins.
The used code is:

html {
margin-left: -45px;
margin-right: -45px
}

And the error that appears in the books:
"An error occurred. If you purchased this item from Amazon, delete the item and download it from the Cloud."

Do you think it's a bug in the new firmware or can the code be modified to fix this behavior?
Thanks
Kindle PW5 with the latest firmware and negative margins work. This is the CSS code I use. I put it at the top of the CSS.
Code:
html {
  margin-right: -45px;
  margin-left: -45px;
  break-inside: avoid !important;
}
JSWolf is offline   Reply With Quote
Old 07-06-2023, 08:09 AM   #5
Quoth
the rook, bossing Never.
Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.
 
Quoth's Avatar
 
Posts: 11,166
Karma: 85874891
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
Try -1.5%
Quoth is offline   Reply With Quote
Advert
Old 07-06-2023, 11:13 AM   #6
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 74,033
Karma: 129333114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Are you putting the negative margins in the ePub CSS and then converting to KF8? What I do is convert to KF8 from ePub and then edit the KF8 to add in the negative margins at the top of the main CSS.
JSWolf is offline   Reply With Quote
Old 07-06-2023, 11:15 AM   #7
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 74,033
Karma: 129333114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by Quoth View Post
Try -1.5%
It's not % vs px. It's something else as the code I posted works for me.
JSWolf is offline   Reply With Quote
Old 07-06-2023, 01:42 PM   #8
Quoth
the rook, bossing Never.
Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.Quoth ought to be getting tired of karma fortunes by now.
 
Quoth's Avatar
 
Posts: 11,166
Karma: 85874891
Join Date: Jun 2017
Location: Ireland
Device: All 4 Kinds: epub eink, Kindle, android eink, NxtPaper11
Quote:
Originally Posted by JSWolf View Post
It's not % vs px. It's something else as the code I posted works for me.
Possibly true. Though never seen negative margins fail on USB transfer. Ages since I've use the "Send to Kindle" service which IMO is best avoided.
Quoth is offline   Reply With Quote
Old 07-06-2023, 01:49 PM   #9
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 74,033
Karma: 129333114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by Quoth View Post
Possibly true. Though never seen negative margins fail on USB transfer. Ages since I've use the "Send to Kindle" service which IMO is best avoided.
We'll just have to wait until the OP comes back and properly describes what is being done.
JSWolf is offline   Reply With Quote
Old 02-11-2024, 08:57 AM   #10
mg10
Connoisseur
mg10 began at the beginning.
 
Posts: 77
Karma: 10
Join Date: Jul 2013
Device: Kindle Scribe, PW, Kobo Aura One
Hi All
Returning to this topic...
With my Scribe I'm using this option in Calibre (styles --> additional css), when converting from epub to azw3, in order to get desired margins:

html {
margin-right: -130px;
margin-left: -130px;
break-inside: avoid !important;
}

After updating a PW, I could see that this option caused an error when opening the book, or trying to change fonts: the one I indicated at the beginning of this thread:
"An error occurred. If you purchased this item from Amazon, delete the item and download it from the Cloud"

In order to avoid this behavior with my Scribe, I stay on an old firmware version because don't know if this error is going to be repeated in the Scribe.

My question is: can someone who has 5.16.6 release or latest, confirm if this happens as well? Someone who uses Calibre and transfers the books through it. I'd like to avoid upgrading if I can no longer use the margins I like, because I won't be able to downgrade it.

Thanks in advance
mg10 is offline   Reply With Quote
Old 02-12-2024, 07:50 AM   #11
mg10
Connoisseur
mg10 began at the beginning.
 
Posts: 77
Karma: 10
Join Date: Jul 2013
Device: Kindle Scribe, PW, Kobo Aura One
Well, sorry, because I repeated this topic in Kindle forum and it seems it's nor permitted.
Regarding solutions, I was testing with upgraded PW and got the same results.
Tried with percentage instead of px, and works just several pages steps, but when you change font type and move among pages, the error appears.
In my Scribe with 5.16.2 firmware, this doesn't happen. I'll keep this version until be sure that with latest firmwares this behaviour doesn't change.
mg10 is offline   Reply With Quote
Old 02-12-2024, 12:00 PM   #12
mg10
Connoisseur
mg10 began at the beginning.
 
Posts: 77
Karma: 10
Join Date: Jul 2013
Device: Kindle Scribe, PW, Kobo Aura One
Quote:
Originally Posted by JSWolf View Post
Kindle PW5 with the latest firmware and negative margins work. This is the CSS code I use. I put it at the top of the CSS.
Code:
html {
  margin-right: -45px;
  margin-left: -45px;
  break-inside: avoid !important;
}
Hi JSWolf
My PW Signature with latest firmware gives this error in converted books with negative margins:
"An error occurred. If you purchased this item from Amazon, delete the item and download it from the Cloud"

The error appears mainly after return to another book. Since that moment, the error doesn't allow pages to go forward or backward, until is restarted.

Last edited by mg10; 02-12-2024 at 02:14 PM.
mg10 is offline   Reply With Quote
Old 02-14-2024, 05:51 AM   #13
mg10
Connoisseur
mg10 began at the beginning.
 
Posts: 77
Karma: 10
Join Date: Jul 2013
Device: Kindle Scribe, PW, Kobo Aura One
Request for moving to Kindle Developer's Corner

Please, is it possible to move this thread to Kindle Developer's Corner? I think it fits better there and will be more active. Thanks
mg10 is offline   Reply With Quote
Old 02-14-2024, 06:00 AM   #14
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 74,033
Karma: 129333114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by mg10 View Post
Hi JSWolf
My PW Signature with latest firmware gives this error in converted books with negative margins:
"An error occurred. If you purchased this item from Amazon, delete the item and download it from the Cloud"

The error appears mainly after return to another book. Since that moment, the error doesn't allow pages to go forward or backward, until is restarted.
I add that code to the KF8 eBook using the editor. I do not convert with that code in place. It works that way. So you have to go to the editor and add your code at the top of the main CSS.
JSWolf is offline   Reply With Quote
Old 02-14-2024, 05:55 PM   #15
mg10
Connoisseur
mg10 began at the beginning.
 
Posts: 77
Karma: 10
Join Date: Jul 2013
Device: Kindle Scribe, PW, Kobo Aura One
Quote:
Originally Posted by JSWolf View Post
I add that code to the KF8 eBook using the editor. I do not convert with that code in place. It works that way. So you have to go to the editor and add your code at the top of the main CSS.
I test It: convert epub to azw3 with default settings on Calibre and no extra CSS, and after converting, edit the azw3 adding the CSS code. Then transfer it to pw. Apparently it works when paging after opening the book first time, but once I change to another book and return to this again or after several movements of pages it starts failing. It's frustrating. Are you using it with latest firmware?
mg10 is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
AZW3 Conversion errs with Calibre 64-bit Me_XMan Conversion 2 10-27-2019 12:50 PM
Conversion epub-->azw3 with negative margins snoeki Conversion 60 12-07-2018 06:03 AM
AZW3 to EPUB Conversion in Calibre Not Working tkil44 Conversion 16 04-23-2016 06:42 AM
epub to azw3 (or mobi) conversion error Hamlet53 Conversion 2 01-25-2014 12:42 PM
Problem with Calibre AZW3 Conversion... thecompanion Conversion 3 12-02-2013 11:18 PM


All times are GMT -4. The time now is 08:28 AM.


MobileRead.com is a privately owned, operated and funded community.