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-20-2012, 07:44 AM   #1
stewacide
Groupie
stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.
 
Posts: 196
Karma: 1086780
Join Date: Jul 2012
Device: Kobo H2O Ed. 2, Glo HD, Glo, Touch
Exclamation any idea why Anandtech feed causing crashes?

https://bugs.launchpad.net/calibre/+...7?comments=all

It crashes my Kobo Touch but it seems I'm not alone and this isn't limited to the Kobo. It's a shame because Anand's often extremely long articles can be a bother to read on screen.

I've never had anything else lock up my reader, but this feed does it reliably and instantly upon opening it.
stewacide is offline   Reply With Quote
Old 09-20-2012, 08:28 AM   #2
Divingduck
Wizard
Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.
 
Posts: 1,161
Karma: 1404241
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
it is not only that your Kobo don't like it. Sony PRS-650, Sony's Software and ADE as well don' like it and hang-up. It seams something in the Epub is wrong. Looking into Sigil shows a lot of problems. At the end it seems there is a need to rework the recipe.
Divingduck is offline   Reply With Quote
Advert
Old 09-20-2012, 09:30 AM   #3
Divingduck
Wizard
Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.
 
Posts: 1,161
Karma: 1404241
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
May be this will work for you:

Spoiler:
Code:
class anan(BasicNewsRecipe):

    title = 'Anandtech'
    description = 'comprehensive Hardware Tests'
    __author__ = 'Oliver Niesner' # 2012-09-20 AGE: update
    use_embedded_content   = False
    language = 'en'
    timefmt = ' [%d %b %Y]'
    max_articles_per_feed = 40
    no_stylesheets = True
    remove_javascript = True
    encoding = 'utf-8'
# 2012-09-20 AGE: remove this section
#    remove_tags=[
#        dict(name='a', attrs={'style':'width:110px; margin-top:0px;text-align:center;'}),
#        dict(name='a', attrs={'style':'width:110px; margin-top:0px; margin-right:20px;text-align:center;'}),
#        {'attrs':{'class':['article_links', 'header', 'body_right']}},
#        {'id':['crumbs']},
#        ]

    keep_only_tags = [{'class':'subbox'}] # 2012-09-20 AGe add
     
    feeds =  [ ('Anandtech', 'http://www.anandtech.com/rss/')]

    def print_version(self,url):
        return url.replace('/show/', '/print/')


Let me know.
Attached Files
File Type: rar AnandTech_upd_AGe_2012-09-20.rar (644 Bytes, 107 views)
Divingduck is offline   Reply With Quote
Old 09-20-2012, 06:03 PM   #4
Divingduck
Wizard
Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.
 
Posts: 1,161
Karma: 1404241
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
I made a final version of this recipe. It includes now all pages of an article. In addition the recipe have a cover.

Spoiler:
Code:
__license__   = 'GPL v3'
__copyright__ = '2008, Kovid Goyal <kovid at kovidgoyal.net>'

'''
Fetch Anandtech.
'''

from calibre.web.feeds.news import BasicNewsRecipe


class anan(BasicNewsRecipe):

    title = 'Anandtech'
    description = 'comprehensive Hardware Tests'
    __author__ = 'Oliver Niesner' # 2012-09-20 AGE: update
    use_embedded_content   = False
    language = 'en'
    timefmt = ' [%d %b %Y]'
    oldest_article        = 7 # 2012-09-20 AGE: update
    max_articles_per_feed = 40
    no_stylesheets = True
    remove_javascript = True
    encoding = 'utf-8'

    cover_url = 'http://www.anandtech.com/content/images/globals/header_logo.png' # 2012-09-20 AGE: new
    masthead_url = 'http://www.anandtech.com/content/images/globals/printheader.png' # 2012-09-20 AGE: update


    remove_tags=[
                  dict(name='a', attrs={'class': 'bluebutton noprint'}),
                  dict(name='img', attrs={'alt': 'header'}),
                 ] # 2012-09-20 AGE: update
  
    feeds =  [ ('Anandtech', 'http://www.anandtech.com/rss/')]

    def print_version(self,url):
        return url.replace('0Cshow0C', '0Cprint0C') # 2012-09-20 AGE: update

Hope, you like it.
DivingDuck
Attached Files
File Type: zip AnandTech_upd_AGe 2012-09-20.zip (714 Bytes, 127 views)
Divingduck is offline   Reply With Quote
Old 09-21-2012, 07:31 AM   #5
stewacide
Groupie
stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.stewacide ought to be getting tired of karma fortunes by now.
 
Posts: 196
Karma: 1086780
Join Date: Jul 2012
Device: Kobo H2O Ed. 2, Glo HD, Glo, Touch
Thanks! Works great - much better than instapaper which was my fallback.
stewacide is offline   Reply With Quote
Advert
Old 09-07-2013, 05:24 AM   #6
Divingduck
Wizard
Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.
 
Posts: 1,161
Karma: 1404241
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
A new update for this recipe.

Spoiler:
Code:
__license__   = 'GPL v3'
__copyright__ = '2008, Kovid Goyal <kovid at kovidgoyal.net>'

'''
Fetch Anandtech.
'''

from calibre.web.feeds.news import BasicNewsRecipe


class anan(BasicNewsRecipe):

    title = 'Anandtech'
    description = 'comprehensive Hardware Tests'
    __author__ = 'Oliver Niesner, Armin Geller' # 2013-09-07 AGE: update
    use_embedded_content   = False
    language = 'en'
    timefmt = ' [%d %b %Y]'
    oldest_article        = 7
    max_articles_per_feed = 40
    no_stylesheets = True
    remove_javascript = True
    encoding = 'utf-8'

    cover_url = 'http://www.anandtech.com/content/images/globals/header_logo.png'
    masthead_url = 'http://www.anandtech.com/content/images/globals/printheader.png'

    keep_only_tags = [
                       dict(name='section', attrs={'class':['main_cont']}),
                     ]
    remove_tags=[                                            # 2013-09-07 AGE: update
                  dict(name='div', attrs={'class':['print', # logo
                                                    'breadcrumb_area noprint',
                                                    'fl-rt noprint',
                                                    'blog_top_right',]})
                 ]
  
    feeds =  [ ('Anandtech', 'http://www.anandtech.com/rss/')]

    def print_version(self,url):
        return url.replace("0Cshow0C", "0Cprint0C") # 2013-09-07 AGE: update
Attached Files
File Type: zip AnandTech_upd_AGe 2013-09-07.zip (798 Bytes, 90 views)
Divingduck is offline   Reply With Quote
Old 02-27-2014, 03:55 AM   #7
Divingduck
Wizard
Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.Divingduck ought to be getting tired of karma fortunes by now.
 
Posts: 1,161
Karma: 1404241
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
A new update for this recipe.
Spoiler:
Code:
__license__   = 'GPL v3'
__copyright__ = '2008, Kovid Goyal <kovid at kovidgoyal.net>'

'''
Fetch Anandtech.
'''

from calibre.web.feeds.news import BasicNewsRecipe


class anan(BasicNewsRecipe):

    title = 'Anandtech'
    description = 'comprehensive Hardware Tests'
    __author__ = 'Oliver Niesner, Armin Geller' # 2014-02-27 AGE: update
    use_embedded_content   = False
    language = 'en'
    timefmt = ' [%d %b %Y]'
    oldest_article        = 7
    max_articles_per_feed = 40
    no_stylesheets = True
    remove_javascript = True
    encoding = 'utf-8'

    cover_url = 'http://www.anandtech.com/content/images/globals/header_logo.png'
    masthead_url = 'http://www.anandtech.com/content/images/globals/printheader.png'

    keep_only_tags = [
                       dict(name='section', attrs={'class':['main_cont']}),
                     ]
    remove_tags=[
                  dict(name='div', attrs={'class':['print',
                                                    'breadcrumb_area noprint',
                                                    'fl-rt noprint',
                                                    'blog_top_right',]})
                 ]
  
    feeds =  [ ('Anandtech', 'http://www.anandtech.com/rss/')]

    def print_version(self,url):
        #return url.replace("0Cshow0C", "0Cprint0C") # 2013-09-07 AGE: update
        return url.replace("/show/", "/print/") # 2014-02-27 AGE: update
Attached Files
File Type: zip AnandTech_upd_AGe 2014-02-27.zip (794 Bytes, 128 views)
Divingduck is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Troubleshooting Highlighting causing crashes caleb72 Amazon Kindle 10 02-02-2011 03:10 AM
My "read" tag idea enhancement for Calibre idea rcuadro Calibre 10 01-20-2011 04:23 PM
iPhone Anandtech: iPhone 4 Redux kjk Apple Devices 0 07-15-2010 06:15 PM
iPhone AnandTech's Thorough(!) Review of the iPhone 4 kjk Apple Devices 1 06-30-2010 02:10 PM
HTML converted books causing crashes - Calibre or PRS-505 issue? Katelyn Calibre 15 10-20-2009 06:08 PM


All times are GMT -4. The time now is 01:51 PM.


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