05-26-2011, 03:18 PM | #1 |
Zealot
Posts: 119
Karma: 100
Join Date: Jan 2011
Location: Germany / NRW /Köln
Device: prs-650 / prs-350 /kindle 3
|
recipe for Aachener Nachrichten - german
Code:
import string, re from calibre import strftime from calibre.web.feeds.recipes import BasicNewsRecipe from calibre.ebooks.BeautifulSoup import BeautifulSoup class AdvancedUserRecipe(BasicNewsRecipe): title = u'Aachener Nachrichten' __author__ = 'schuster' oldest_article = 1 max_articles_per_feed = 100 use_embedded_content = False language = 'de' remove_javascript = True cover_url = 'http://www.an-online.de/einwaage/images/an_logo.png' masthead_url = 'http://www.an-online.de/einwaage/images/an_logo.png' extra_css = ''' .fliesstext_detail:{margin-bottom:10%;} .headline_1:{margin-bottom:25%;} b{font-family:Arial,Helvetica,sans-serif; font-weight:200;font-size:large;} a{font-family:Arial,Helvetica,sans-serif; font-weight:400;font-size:large;} ll{font-family:Arial,Helvetica,sans-serif; font-weight:100;font-size:large;} h4{font-family:Arial,Helvetica,sans-serif; font-weight:normal;font-size:small;} img {min-width:300px; max-width:600px; min-height:300px; max-height:800px} dd{font-family:Arial,Helvetica,sans-serif;font-size:large;} body{font-family:Helvetica,Arial,sans-serif;font-size:small;} ''' keep_only_tags = [ dict(name='span', attrs={'class':['fliesstext_detail', 'headline_1', 'autor_detail']}), dict(id=['header-logo']) ] feeds = [(u'Euregio', u'http://www.an-online.de/an/rss/Euregio.xml'), (u'Aachen', u'http://www.an-online.de/an/rss/Aachen.xml'), (u'Nordkreis', u'http://www.an-online.de/an/rss/Nordkreis.xml'), (u'Düren', u'http://www.an-online.de/an/rss/Dueren.xml'), (u'Eiffel', u'http://www.an-online.de/an/rss/Eifel.xml'), (u'Eschweiler', u'http://www.an-online.de/an/rss/Eschweiler.xml'), (u'Geilenkirchen', u'http://www.an-online.de/an/rss/Geilenkirchen.xml'), (u'Heinsberg', u'http://www.an-online.de/an/rss/Heinsberg.xml'), (u'Jülich', u'http://www.an-online.de/an/rss/Juelich.xml'), (u'Stolberg', u'http://www.an-online.de/an/rss/Stolberg.xml'), (u'Ratgebenr', u'http://www.an-online.de/an/rss/Ratgeber.xml')] |
11-28-2012, 04:49 AM | #2 |
Wizard
Posts: 1,161
Karma: 1404241
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
|
I made an update for this recipe. The new recipe includes all feeds. Feel free to use it or modify it for your needs.
Spoiler:
|
Advert | |
|
11-30-2012, 02:49 AM | #3 |
Member
Posts: 10
Karma: 10
Join Date: Nov 2012
Device: Sony PRS-T1, PocketBook 902
|
Hi,
thank you very much but an additional question Yesterday with Sony t1 connected, no problem. Today with Pocketbook pro 902 connectet an error message, details you´ll find below. calibre, version 0.9.8 (win32, isfrozen: True) Konvertierungsfehler: Fehlgeschlagen: Nachrichten abrufen von Aachener Nachrichten Nachrichten abrufen von Aachener Nachrichten Resolved conversion options calibre version: 0.9.8 {'asciiize': False, 'author_sort': None, 'authors': None, 'base_font_size': 0, 'book_producer': None, 'change_justification': 'original', 'chapter': None, 'chapter_mark': 'pagebreak', 'comments': None, 'cover': None, 'debug_pipeline': None, 'dehyphenate': True, 'delete_blank_paragraphs': True, 'disable_font_rescaling': False, 'dont_download_recipe': False, 'dont_split_on_page_breaks': True, 'duplicate_links_in_toc': False, 'embed_font_family': None, 'enable_heuristics': False, 'epub_flatten': False, 'extra_css': None, 'extract_to': None, 'filter_css': None, 'fix_indents': True, 'flow_size': 260, 'font_size_mapping': None, 'format_scene_breaks': True, 'html_unwrap_factor': 0.4, 'input_encoding': None, 'input_profile': <calibre.customize.profiles.InputProfile object at 0x02B70370>, 'insert_blank_line': False, 'insert_blank_line_size': 0.5, 'insert_metadata': False, 'isbn': None, 'italicize_common_cases': True, 'keep_ligatures': False, 'language': None, 'level1_toc': None, 'level2_toc': None, 'level3_toc': None, 'line_height': 0, 'linearize_tables': False, 'lrf': False, 'margin_bottom': 5.0, 'margin_left': 5.0, 'margin_right': 5.0, 'margin_top': 5.0, 'markup_chapter_headings': True, 'max_toc_links': 50, 'minimum_line_height': 120.0, 'no_chapters_in_toc': False, 'no_default_epub_cover': False, 'no_inline_navbars': False, 'no_svg_cover': False, 'output_profile': <calibre.customize.profiles.SonyReaderOutput object at 0x02B70830>, 'page_breaks_before': None, 'prefer_metadata_cover': False, 'preserve_cover_aspect_ratio': False, 'pretty_print': True, 'pubdate': None, 'publisher': None, 'rating': None, 'read_metadata_from_opf': None, 'remove_fake_margins': True, 'remove_first_image': False, 'remove_paragraph_spacing': False, 'remove_paragraph_spacing_indent_size': 1.5, 'renumber_headings': True, 'replace_scene_breaks': '', 'search_replace': None, 'series': None, 'series_index': None, 'smarten_punctuation': False, 'sr1_replace': '', 'sr1_search': '', 'sr2_replace': '', 'sr2_search': '', 'sr3_replace': '', 'sr3_search': '', 'start_reading_at': None, 'subset_embedded_fonts': False, 'tags': None, 'test': False, 'timestamp': None, 'title': None, 'title_sort': None, 'toc_filter': None, 'toc_threshold': 6, 'unsmarten_punctuation': False, 'unwrap_lines': True, 'use_auto_toc': False, 'verbose': 2} InputFormatPlugin: Recipe Input running Using custom recipe Python function terminated unexpectedly (Error Code: 1) Traceback (most recent call last): File "site.py", line 132, in main File "site.py", line 109, in run_entry_point File "site-packages\calibre\utils\ipc\worker.py", line 186, in main File "site-packages\calibre\gui2\convert\gui_conversion.py", line 25, in gui_convert File "site-packages\calibre\ebooks\conversion\plumber.py", line 1009, in run File "site-packages\calibre\customize\conversion.py", line 239, in __call__ File "site-packages\calibre\ebooks\conversion\plugins\recipe_ input.py", line 109, in convert File "site-packages\calibre\web\feeds\news.py", line 891, in download File "site-packages\calibre\web\feeds\news.py", line 1063, in build_index File "site-packages\calibre\web\feeds\news.py", line 1480, in parse_feeds File "site-packages\calibre\web\feeds\news.py", line 381, in get_feeds NotImplementedError Best regards dkosse |
11-30-2012, 03:52 AM | #4 |
Wizard
Posts: 1,161
Karma: 1404241
Join Date: Nov 2010
Location: Germany
Device: Sony PRS-650
|
Just check the recipe with Calibre 0.9.8. Can't see any problems with the recipe.
Best regards, DD |
11-30-2012, 09:37 AM | #5 |
Member
Posts: 10
Karma: 10
Join Date: Nov 2012
Device: Sony PRS-T1, PocketBook 902
|
Hi DD,
after updateing to 0.9.8 everything is going well, thank you very much dkosse |
Advert | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Gute Nachrichten für die Besitzer von 302 Geräten | review | PocketBook | 22 | 03-21-2011 02:19 PM |
Nachrichten per Calibre aufs Pocketbook | Sturgis | PocketBook | 57 | 01-04-2010 03:24 AM |
Eigene Nachrichten richtig kategorisieren | ganymede | PocketBook | 2 | 12-15-2009 08:13 AM |
Schon wieder schlechte Nachrichten | Marc_liest | Lounge | 13 | 05-27-2009 02:54 PM |