We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sometimes no publication date is available and a blank string is returned. However the db model expects a date time.
Possible fix in scraper.Scraper.html_article:
scraper.Scraper.html_article
if not isinstance(a.publish_date, datetime.datetime): article_pub_date = datetime.datetime.now() else: article_pub_date = a.publish_date
The text was updated successfully, but these errors were encountered:
Does it make more sense to use None/NULL? It seems misleading to say that the publication date of an article is when the scraper ran.
Sorry, something went wrong.
I think None makes more sense. If there had to be a date, a fallback could be the latest date mentioned in the article ( or the latest Report).
Yeah agreed None makes more sense now that I think about it.
Yep!
No branches or pull requests
Sometimes no publication date is available and a blank string is returned. However the db model expects a date time.
Possible fix in
scraper.Scraper.html_article
:The text was updated successfully, but these errors were encountered: