Skip to content

Commit

Permalink
Merge pull request #151 from Lukas0907/lwn
Browse files Browse the repository at this point in the history
Fixes for Ö1 and LWN
  • Loading branch information
Lukas0907 committed Aug 16, 2018
2 parents 0bf9ab9 + 453dc64 commit dfee6af
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions feeds/spiders/lwn_net.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,10 +164,14 @@ def _parse_article(self, response):
".MakeALink",
"br",
]
change_tags = {
"div.BigQuote": "blockquote",
}
il = FeedEntryItemLoader(
response=response,
parent=response.meta["il"],
remove_elems=remove_elems,
change_tags=change_tags,
base_url="https://{}".format(self.name),
)
text = response.css(".ArticleText").extract_first()
Expand Down
2 changes: 1 addition & 1 deletion feeds/spiders/oe1_orf_at.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def _parse_broadcast(self, response):
),
)
il.add_value("category", broadcast["tags"])
if "no_canonical_url" not in broadcast["url"]:
if broadcast["url"] and "no_canonical_url" not in broadcast["url"]:
yield scrapy.Request(
broadcast["url"], self._parse_show, dont_filter=True, meta={"il": il}
)
Expand Down

0 comments on commit dfee6af

Please sign in to comment.