Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader > Kobo Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 05-01-2023, 12:42 PM   #31
bouchacha
Junior Member
bouchacha began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Apr 2023
Device: Kobo Clara 2E
Quote:
Originally Posted by qkqw View Post
You are mentioning two different issues:

- The two screenshots are from the Pocket overview section. In most cases images do work properly there (even with acoup), and in most cases it's just a sync issue. I've had the issue that the same image will be displayed in the overview but not inside the article due to being a PNG
- Sometimes whole sections and/or images are missing from the article. That often happens with <code> sections, movies and advanced <picture> elements. In those cases you're right, there's not much we can do as that section is simply not there. If you check with the web view however, you'll notice that the same section is missing, so it's more likely a Pocket issue than a Kobo one.
Thank you that makes sense. Would it be possible for someone to post a screenshot of what it looks like on Kobo when an image is missing? I ran the script from this thread while I had about 1500 articles downloaded via Pocket and it finished instantly which surprised me. I can't tell if it's working as intended.
bouchacha is offline   Reply With Quote
Old 05-06-2023, 06:35 AM   #32
qkqw
Connoisseur
qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.
 
Posts: 62
Karma: 143000
Join Date: Apr 2022
Device: Kobo Libra 2
Sure, there will be a small image-not-found icon instead of an image. If you don't see such an icon, Pocket will already have removed the image before passing it to Kobo.
Attached Thumbnails
Click image for larger version

Name:	kobo-2023-05-06-01-21-22.png
Views:	210
Size:	93.9 KB
ID:	201426  
qkqw is offline   Reply With Quote
Advert
Old 05-29-2023, 11:18 AM   #33
just_jeepin
Addict
just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.
 
just_jeepin's Avatar
 
Posts: 305
Karma: 1010848
Join Date: Oct 2005
Device: Kobo Libra 2
can't get it to work

I can't get it to work.

I added this to the nm config menu.
Code:
menu_item  :library  :Fix Pocket Images  :cmd_spawn  :quiet:/bin/sh /mnt/onboard/.adds/pocket/fix.sh
  chain_success  :dbg_toast  :Done
I then extracted pocket.zip to /mnt/onboard/.adds/pocket.

And rebooted. It doesn't show up in the main menu or the nm while in Pocket.

Last edited by just_jeepin; 05-29-2023 at 11:20 AM. Reason: typo
just_jeepin is offline   Reply With Quote
Old 05-29-2023, 01:08 PM   #34
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 40,506
Karma: 156983616
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by just_jeepin View Post
I can't get it to work.

I added this to the nm config menu.
Code:
menu_item  :library  :Fix Pocket Images  :cmd_spawn  :quiet:/bin/sh /mnt/onboard/.adds/pocket/fix.sh
  chain_success  :dbg_toast  :Done
I then extracted pocket.zip to /mnt/onboard/.adds/pocket.

And rebooted. It doesn't show up in the main menu or the nm while in Pocket.
Does it show up when you are in the Books (library) view?
DNSB is offline   Reply With Quote
Old 05-29-2023, 05:59 PM   #35
just_jeepin
Addict
just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.
 
just_jeepin's Avatar
 
Posts: 305
Karma: 1010848
Join Date: Oct 2005
Device: Kobo Libra 2
It's not showing up in NickelMenu on the homepage, pocket or my books page.
just_jeepin is offline   Reply With Quote
Advert
Old 05-29-2023, 11:36 PM   #36
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 40,506
Karma: 156983616
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by just_jeepin View Post
It's not showing up in NickelMenu on the homepage, pocket or my books page.
A bit strange. I added the following 2 lines to my nm_config.txt file:


Code:
	 menu_item  :main  :Fix Pocket Images  :cmd_spawn  :quiet:/bin/sh /mnt/onboard/.adds/pocket/fix.sh
  chain_success  :dbg_toast  :Done
# ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- #

menu_item  :library  :Fix Pocket Images  :cmd_spawn  :quiet:/bin/sh /mnt/onboard/.adds/pocket/fix.sh
  chain_success  :dbg_toast  :Done
  
# ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- #
#
I don't use Pocket so I have never tried to use NickelMenu while using Pocket.

Then I dragged the pocket directory from the .zip file into the .adds directory on my Kobo ereader. When I opened NickelMenu, I saw the Fix Pocket Images directory and when I tapped on it, I got the Done toast. Sadly, I don't use Pocket but don't think that should have any effect on the test. When I look at the .adds directory, I see the nm directory and the pocket directory. In the pocket directory, I see the fix.sh and magick files and the fonts and lib directories.
Attached Thumbnails
Click image for larger version

Name:	screen_001.png
Views:	194
Size:	37.9 KB
ID:	201771  

Last edited by DNSB; 05-29-2023 at 11:38 PM.
DNSB is offline   Reply With Quote
Old 05-31-2023, 06:36 AM   #37
xyclonei
Zealot
xyclonei put the bomp in the bomp-a-bomp-a-bomp.xyclonei put the bomp in the bomp-a-bomp-a-bomp.xyclonei put the bomp in the bomp-a-bomp-a-bomp.xyclonei put the bomp in the bomp-a-bomp-a-bomp.xyclonei put the bomp in the bomp-a-bomp-a-bomp.xyclonei put the bomp in the bomp-a-bomp-a-bomp.xyclonei put the bomp in the bomp-a-bomp-a-bomp.xyclonei put the bomp in the bomp-a-bomp-a-bomp.xyclonei put the bomp in the bomp-a-bomp-a-bomp.xyclonei put the bomp in the bomp-a-bomp-a-bomp.xyclonei put the bomp in the bomp-a-bomp-a-bomp.
 
xyclonei's Avatar
 
Posts: 106
Karma: 67444
Join Date: Dec 2018
Device: Kobo Clara HD
Quote:
Originally Posted by just_jeepin View Post
I can't get it to work.

I added this to the nm config menu.
Code:
menu_item  :library  :Fix Pocket Images  :cmd_spawn  :quiet:/bin/sh /mnt/onboard/.adds/pocket/fix.sh
  chain_success  :dbg_toast  :Done
I then extracted pocket.zip to /mnt/onboard/.adds/pocket.

And rebooted. It doesn't show up in the main menu or the nm while in Pocket.
Since the entry is in the Library menu, you will have to tap on 'My Books' > 3 horizontal dot menu on the top right > Fix Pocket Images.
xyclonei is offline   Reply With Quote
Old 05-31-2023, 12:43 PM   #38
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 40,506
Karma: 156983616
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by xyclonei View Post
Since the entry is in the Library menu, you will have to tap on 'My Books' > 3 horizontal dot menu on the top right > Fix Pocket Images.
Since @just_jeepin posted in a message:
Quote:
It's not showing up in NickelMenu on the homepage, pocket or my books page.
I've hit the limit of what I can offer in the line of troubleshooting from what has been posted. I am wondering if he has issues with the construction of his NM config file(s).
DNSB is offline   Reply With Quote
Old 05-31-2023, 08:02 PM   #39
just_jeepin
Addict
just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.
 
just_jeepin's Avatar
 
Posts: 305
Karma: 1010848
Join Date: Oct 2005
Device: Kobo Libra 2
Quote:
Originally Posted by xyclonei View Post
Since the entry is in the Library menu, you will have to tap on 'My Books' > 3 horizontal dot menu on the top right > Fix Pocket Images.
Thank you, it was hiding in that menu! I changed :library to :main and it's in the NickelMenu menu.

Last edited by just_jeepin; 05-31-2023 at 08:12 PM.
just_jeepin is offline   Reply With Quote
Old 08-14-2023, 11:11 AM   #40
logger232
Junior Member
logger232 began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Aug 2023
Device: kobo aura 1
I did everything as per the instructions, but when I click on the 'fix Pocket images' from the nicklemenu in the articles section, I instantly get a toast saying "Done" but the images are not fixed, I tried powering the device on and off, I deleted and re-extracted the pocket zip file in the .adds directory but to no avail.
can someone please help me?
logger232 is offline   Reply With Quote
Old 11-23-2023, 12:05 PM   #41
just_jeepin
Addict
just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.
 
just_jeepin's Avatar
 
Posts: 305
Karma: 1010848
Join Date: Oct 2005
Device: Kobo Libra 2
I'm having the same issue.
just_jeepin is offline   Reply With Quote
Old 01-25-2024, 09:14 PM   #42
just_jeepin
Addict
just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.just_jeepin ought to be getting tired of karma fortunes by now.
 
just_jeepin's Avatar
 
Posts: 305
Karma: 1010848
Join Date: Oct 2005
Device: Kobo Libra 2
Any updates on a fixed script?
just_jeepin is offline   Reply With Quote
Old 01-26-2024, 08:09 AM   #43
qkqw
Connoisseur
qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.
 
Posts: 62
Karma: 143000
Join Date: Apr 2022
Device: Kobo Libra 2
Quote:
Originally Posted by just_jeepin View Post
Any updates on a fixed script?
The script is working fine for most of us. The "done" toast will be shown immediately, it doesn't wait until all images are processed.

You can try this version which uses a log and is able to show the current status: https://www.mobileread.com/forums/sh...2&postcount=21
qkqw is offline   Reply With Quote
Old 03-03-2024, 07:00 PM   #44
qkqw
Connoisseur
qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.qkqw is at one with the great books of the world.
 
Posts: 62
Karma: 143000
Join Date: Apr 2022
Device: Kobo Libra 2
Quote:
Originally Posted by xyclonei View Post
I've been scratching my head over this.

The below NM config displays Done when the script process is spawned and not when the Pocket image conversions are done.
I've been thinking about this lately and came up with a real easy solution. If you have qndb (NickelDBus) installed, you can just call it to display a toast message at the end of the script, for example:

Code:
qndb -m mwcToast 3000 "Finished converting"
qkqw is offline   Reply With Quote
Old 03-08-2024, 08:08 PM   #45
vesko
Junior Member
vesko began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Mar 2024
Device: Kobo Libra 2
Thank you for sharing all of this. I have not tried your script directly yet but it has been really interesting to read because I'm working on my own project to do with improving Pocket's awful article parsing and broken images.

I'm building my own self-hosted "pre-processor" that can re-format articles to make them easier for pocket's servers to parse and reduce instances of missing paragraphs / sections and images. I kept hitting the missing images problem though, and googling for it brought me here. Very glad to hear that the issue is solvable by converting image formats into jpegs.

I saw your other forum post where you found that pocket have an image proxy service that they use in certain situations to convert PNGs to JPEGs via pocket-image-cache.com. I think I might have a go at re-routing article image URLs to use their converter.

Many thanks again for the useful pointer!

(My code is a bit too early stage and too customised to my setup to share yet but I might follow up if there's any interest.)
vesko is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
fixing images? PandathePanda Workshop 8 11-15-2017 04:49 AM
Script to resize images to 2 Million Pixels shorshe ePub 14 06-28-2013 01:35 PM
Creation of Complex Script E-Book Using Images for Every Word? sungkhum Conversion 8 10-26-2011 05:20 PM
Script for fixing covers on B&N Nook Color jmricker Devices 0 06-28-2011 02:45 PM
Linux script for images to Kindle Screensaver soymicmic Kindle Developer's Corner 4 01-28-2011 12:20 PM


All times are GMT -4. The time now is 04:19 AM.


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