Skip to content

Commit

Permalink
activity/scraper.py: Error if source data missing
Browse files Browse the repository at this point in the history
When the issue data JSON is missing, an exception
should occur then, instead of when failing to load
the JSON.

Related to coala#27
  • Loading branch information
jayvdb committed Dec 10, 2017
1 parent 741a8b8 commit 66b7505
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions activity/scraper.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ def get_data(self):
issues_url = 'http://' + org_name + '.github.io/gh-board/issues.json'

content = requests.get(issues_url)
content.raise_for_status()
parsed_json = content.json()

real_data = Scraper(parsed_json['issues'], datetime.datetime.today())
Expand Down

0 comments on commit 66b7505

Please sign in to comment.