Add sgmllib 3k port so feedparser can fix relative urls
This commit is contained in:
parent
5e657e9807
commit
d179c1bd03
2 changed files with 4 additions and 2 deletions
|
@ -32,3 +32,4 @@ rq==0.5.2
|
|||
six==1.9.0
|
||||
uWSGI==2.0.10
|
||||
websockets==2.4
|
||||
sgmllib3k==1.0.0
|
||||
|
|
|
@ -299,8 +299,9 @@ def is_content_equal(e1, e2):
|
|||
|
||||
def process_xml_feed_for_new_entries(feed, content, backfill, now):
|
||||
current_app.logger.debug('fetching xml feed: %s', feed)
|
||||
|
||||
parsed = feedparser.parse(content)
|
||||
parsed = feedparser.parse(content, response_headers={
|
||||
'content-location': feed.feed,
|
||||
})
|
||||
feed_props = parsed.get('feed', {})
|
||||
default_author_url = feed_props.get('author_detail', {}).get('href')
|
||||
default_author_name = feed_props.get('author_detail', {}).get('name')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue