Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Recipes

Notices

Reply
 
Thread Tools Search this Thread
Old 09-10-2011, 10:10 AM   #1
Mixx
Zealot
Mixx has a complete set of Star Wars action figures.Mixx has a complete set of Star Wars action figures.Mixx has a complete set of Star Wars action figures.Mixx has a complete set of Star Wars action figures.
 
Posts: 143
Karma: 387
Join Date: Sep 2010
Device: Kindle 3
Recipes need update

Hi,

I trying out a number of recipes and wonder if we should have a sticky to identify those recipes that do not work properly anymore and need an update.

I'd like to add
Code:
Business Week
CIO (CIO Magazin)
Inquirer.net (The Inquirer)
My hope is that fellow forum readers with the right skills might want to fix one or two, if their time permits.

We could even have a voting list to see which are (or rather would be) the most popular ones.

Regards, Mixx
Mixx is offline   Reply With Quote
Old 09-11-2011, 04:11 AM   #2
julio:map
Member
julio:map began at the beginning.
 
Posts: 23
Karma: 12
Join Date: Jul 2011
Device: Cool-er
Quote:
Originally Posted by Mixx View Post
Hi,

I trying out a number of recipes and wonder if we should have a sticky to identify those recipes that do not work properly anymore and need an update.

I'd like to add
Code:
Business Week
CIO (CIO Magazin)
Inquirer.net (The Inquirer)
My hope is that fellow forum readers with the right skills might want to fix one or two, if their time permits.

We could even have a voting list to see which are (or rather would be) the most popular ones.

Regards, Mixx
There are two recipes for Business Week.
One of them over-cuts articles... wiith this I mean that some articles do "show" and they show "perfect"... while others simply are missing (the article, not the item list on the menu). In fact, the recipe generates a blank page for those articles, with an hyperlink to the missing page, and the hyperlink is correct.
The other one (the second recipe for business week) shows all the articles, but all of them with lots of extra information (webpage navigation menus, and so on).

With respect to CIO. I use the provided recipe, and it works PERFECT. The only "but" I can add is that it is not a recipe for the CIO magazine, but for the RSS feed that the site provides with daily news.

I don't use the Inquirer.

Best regards.
julio:map is offline   Reply With Quote
Advert
Old 09-11-2011, 05:04 AM   #3
julio:map
Member
julio:map began at the beginning.
 
Posts: 23
Karma: 12
Join Date: Jul 2011
Device: Cool-er
I have a recipe for CIO Magazine. (please find it enclosed, and use it or not at your own risk)

My knowledge about Python, Beautiful soup, Mechanize or CSS is null.
I've only tested it from my windows environment. (No Unix, Mac or others).
I've only tested it on the last issue.
But it worked. (and is documented in "perfect Spanglish" for future reviews)

It "oficially" retrieves the last issue when launched.

Best regards.
Attached Files
File Type: zip CIO_MAGAZINE.zip (2.8 KB, 78 views)
julio:map is offline   Reply With Quote
Old 09-11-2011, 10:37 AM   #4
julio:map
Member
julio:map began at the beginning.
 
Posts: 23
Karma: 12
Join Date: Jul 2011
Device: Cool-er
Quote:
Originally Posted by Mixx View Post
Hi,

I trying out a number of recipes and wonder if we should have a sticky to identify those recipes that do not work properly anymore and need an update.

I'd like to add
Code:
Business Week
CIO (CIO Magazin)
Inquirer.net (The Inquirer)
My hope is that fellow forum readers with the right skills might want to fix one or two, if their time permits.

We could even have a voting list to see which are (or rather would be) the most popular ones.

Regards, Mixx
Regarding Business week, here is what I have done:

I have reviewed the business week recipe (the one from Kovid Goyal and Darko Miletic, which is the one that works)

It fails because business week is not consistent about how it writes its pages.

I've had to change two thigs:

At line 44:
keep_only_tags = [dict(name='div', attrs={'id':['story-body','storyBody]})]

for
keep_only_tags = [dict(name='div', attrs={'id':['story-body','storyBody','article_body','articleBody']})]


some of its pages have the main article under "StoryBody" DIV, but others are under "article_body" DIV (that is why they don't work)

At line 92:
rurl = url.replace('http://www.businessweek.com/','http://www.businessweek.com/print/')
for
if '/magazine' in url:
rurl = url.replace('http://www.businessweek.com/','http://www.businessweek.com/printer/')
else:
rurl = url.replace('http://www.businessweek.com/','http://www.businessweek.com/print/')

Some of its articles have a printer page whose name is built in a different way

This way, the recipe continues to have some extra data (that needs to be deleted) but at least works.

Hope that someone can make a better correction. For the moment I attach my changes just in case someone may find them useful.

Best regards.
Attached Files
File Type: zip business week.zip (1.7 KB, 109 views)
julio:map is offline   Reply With Quote
Old 09-11-2011, 12:14 PM   #5
julio:map
Member
julio:map began at the beginning.
 
Posts: 23
Karma: 12
Join Date: Jul 2011
Device: Cool-er
I've had to make another change.

in print_version, I have changed
if '/news/' in url or '/blog/ in url':
for
if '/news/' in url or '/blog/' in url:

This was an error in the original recipe (or in my copy).

Now it seems to be working well.

Best regards
Attached Files
File Type: zip Business Week.zip (1.7 KB, 122 views)
julio:map is offline   Reply With Quote
Advert
Old 09-11-2011, 05:38 PM   #6
Krittika Goyal
Vox calibre
Krittika Goyal ought to be getting tired of karma fortunes by now.Krittika Goyal ought to be getting tired of karma fortunes by now.Krittika Goyal ought to be getting tired of karma fortunes by now.Krittika Goyal ought to be getting tired of karma fortunes by now.Krittika Goyal ought to be getting tired of karma fortunes by now.Krittika Goyal ought to be getting tired of karma fortunes by now.Krittika Goyal ought to be getting tired of karma fortunes by now.Krittika Goyal ought to be getting tired of karma fortunes by now.Krittika Goyal ought to be getting tired of karma fortunes by now.Krittika Goyal ought to be getting tired of karma fortunes by now.Krittika Goyal ought to be getting tired of karma fortunes by now.
 
Krittika Goyal's Avatar
 
Posts: 412
Karma: 1175230
Join Date: Jan 2009
Device: Sony reader prs700, kobo
inquirer recipe is attached.
Attached Files
File Type: zip inquirer.recipe.zip (1.2 KB, 113 views)
Krittika Goyal is offline   Reply With Quote
Old 09-15-2011, 03:53 PM   #7
Mixx
Zealot
Mixx has a complete set of Star Wars action figures.Mixx has a complete set of Star Wars action figures.Mixx has a complete set of Star Wars action figures.Mixx has a complete set of Star Wars action figures.
 
Posts: 143
Karma: 387
Join Date: Sep 2010
Device: Kindle 3
Oh, terrific, thank you very much!

Thanxx, Mixx

PS: I still think that it would be a good idea to have a place to flag the recipes that have an issue.
Mixx is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
update for JBPress and NBOnline recipes. adonishi Recipes 0 07-19-2011 03:14 AM
won't update...after completing the update cycle edge returns to the first screen WeAreBorrg enTourage Archive 2 03-18-2011 06:39 PM
How can I update creation time for a title when I update the book info or convert it setherd Calibre 3 10-30-2010 01:51 PM
Firmware Update Can I reinstall the official amazon update after the update file from this site ? yuenslhk Amazon Kindle 2 06-20-2010 11:24 AM
Update on Google eBook Sales Plan Update poohbear_nc News 6 05-05-2010 09:00 AM


All times are GMT -4. The time now is 03:13 AM.


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