Skip to content

Commit

Permalink
Merge pull request #818 from ix5/feedparser-warn
Browse files Browse the repository at this point in the history
contrib: import_blogger: Warn on missing feedparser, run flake8 in contrib/ as well
  • Loading branch information
ix5 committed Mar 21, 2022
2 parents d7c8707 + d8d595f commit a0494cc
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ init:
npm install

flakes:
flake8 isso/ --count --max-line-length=127 --show-source --statistics
flake8 isso/ contrib/ --count --max-line-length=127 --show-source --statistics

# Note: It doesn't make sense to split up configs by output file with
# webpack, just run everything at once
Expand Down
11 changes: 9 additions & 2 deletions contrib/import_blogger.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,16 @@
"""

import json

import feedparser
import time

try:
import feedparser
except ImportError:
print("Error: Package feedparser not installed! You can install it via "
"'pip install feedparser' inside your virtualenv.")
import sys
sys.exit(1)

from urllib.parse import urlparse


Expand Down

0 comments on commit a0494cc

Please sign in to comment.