Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(2)  |  Call(1)  |  Derive(0)  |  Import(1)

        def add_entry(rss, comic, num_entries=20):
    while rss.items and rss.items[0].title.endswith('error'):
        rss.items.pop(0)
    rss.items[0:0] = [
        rss_gen.RSSItem(
            title='New {0} episode'.format(comic.full_name),
            description='Episode {0} provided by dripfeed'.format(comic.progress.episode),
            link=comic.progress.next_url,
            pubDate=datetime.utcnow()
        )
    ]
    rss.items = rss.items[:num_entries]
        


src/d/r/dripfeed-1.0.1/dripfeed/__init__.py   dripfeed(Download)
import os
 
from .rss import parse_rss, add_error_entry, add_entry, init_rss
from docopt import docopt
from .comics import get_comic, XPathComic, remove_comic, get_configured_comics, put_comic
def write_success_rss(comic):
    _write_rss(comic, lambda parsed_rss: add_entry(parsed_rss, comic))
 
 
if __name__ == '__main__':