fkztw / ptt_statistics

Get the statistics of a board on PTT.
GNU General Public License v3.0
0 stars 0 forks source link

Crashed when the article is not found. #9

Closed fkztw closed 8 years ago

fkztw commented 8 years ago
Traceback (most recent call last):
  File "/root/ptt_statistics/ptt_statistics/ptt_statistics.py", line 113, in store_board_info
    article = articles.next()                                                                          File "/usr/local/lib/python3.4/dist-packages/ptt_crawler/article_list.py", line 20, in next            return self.next_article()
  File "/usr/local/lib/python3.4/dist-packages/ptt_crawler/article_list.py", line 31, in next_article
    return Article(article_url, self.board)
  File "/usr/local/lib/python3.4/dist-packages/ptt_crawler/article.py", line 13, in __init__
    self.data = self.board.get_data(self.path)                                                         File "/usr/local/lib/python3.4/dist-packages/ptt_crawler/board.py", line 46, in get_data               raise Exception(msg)
Exception: HTTP request failed! status: 404, url: https://www.ptt.cc/bbs/sex/M.1426189881.A.403.html