![]() |
#1 |
Junior Member
![]() Posts: 2
Karma: 10
Join Date: Jan 2011
Device: Kindle
|
How to cancel 'book' generation if no articles found
I have several recipes customised to only download articles from the last day. The trouble is I end up with 'books' with no content as not all blogs get posts every day.
Is there a way to get the recipe to 'cancel' if no articles / new articles are found? Or is there an alternative approach? I suspect I have missed something obvious somewhere as this would seem a common requirement to me. Regards, Alan |
![]() |
![]() |
![]() |
#2 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,363
Karma: 27230406
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Override the parse_feeds method and raise an exception when no articles are present.
|
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Junior Member
![]() Posts: 2
Karma: 10
Join Date: Jan 2011
Device: Kindle
|
After a quick spot of Python training I have implemented the above and it does work (of course;-) but it does leave a nasty error dialog on the screen instead of exiting gracefully.
Is there anything I can do to make this more graceful? Please excuse my lack of Python knowledge if this is what is holding me back from realising the answer. |
![]() |
![]() |
![]() |
#4 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,363
Karma: 27230406
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
No, there isn't.
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
E-book device (E Ink, 2nd-generation) comparison matrix | Alexander Turcic | Which one should I buy? | 107 | 11-16-2011 04:03 AM |
Digital Content Production and Instant Multiple Book Format Generation Solution | Munish | News | 0 | 05-18-2010 07:59 AM |
Free e-book: My Digital Generation | Bob Russell | Deals and Resources (No Self-Promotion or Affiliate Links) | 7 | 02-16-2008 10:39 AM |
Found via Teleread.org: Two Articles abotu the Iliad | CommanderROR | iRex | 5 | 04-18-2006 10:18 AM |
Next generation e-book hardware by Microsoft? | Alexander Turcic | News | 3 | 04-15-2005 08:50 PM |