Python Forum

Full Version: Long-term stable source to get news headlines with Python?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I am planning to do multiple data visualisations of the sentiment of real-time news headlines from different newspapers. The visualisations will be displayed on different sites (with pyhisical LED screens) for a long period. I am trying to find the best way with Python to get the news according to my needs:

  • The source has to be stable in its format because the piece its gonna last for a long period. That's why I am not sure about considering web scraping.

  • I want to be able to have multiple instances(let's say 10) of the visualisation each displaying different content. That's why I am not sure about using Twitter API, due to limited requests and having to depend on a Twitter account.
The only option that comes to my mind is using RSS feeds as its something solid and easy to integrate with Python, but at the same time the use of RSS feeds is in decline and less digital newspapers are using them. I would like to have as much access to different newspapers as possible.

You guys know any other options or have any tips on how to handle this?

Thanks in advance, Joan.
(Dec-22-2021, 04:36 PM)Larz60+ Wrote: [ -> ]check out: https://newsapi.org/

Thanks for the answer! I already know news API and it doesn't fit my needs. I cannot choose the newspappers I want to get the news from.
Well, in a different direction, perhaps:
PyPi: https://pypi.org/project/newspaper3k/

GitHub: https://github.com/codelucas/newspaper/
(Dec-23-2021, 12:41 AM)Larz60+ Wrote: [ -> ]Well, in a different direction, perhaps:
PyPi: https://pypi.org/project/newspaper3k/

GitHub: https://github.com/codelucas/newspaper/

I already know this source too Shy . It's not very reliable due to web scraping and I see lots of people having issues with it. Thanks tho for your link Smile .