Feed parsing works in command line, but not in python file.
person-al opened this issue · 2 comments
person-al commented
Hi! Would love some help understanding what I'm doing wrong here.
I'm using feedparser to parse the following url: https://rss.nytimes.com/services/xml/rss/nyt/Science.xml
I notice that if I test feedparser using the command line's python interpreter, everything is fine. But if I create a python file that tries to parse it, I get the following:
{'bozo': 1, 'entries': [], 'feed': {}, 'headers': {}, 'encoding': 'utf-8', 'version': '', 'bozo_exception': SAXParseException('syntax error'), 'namespaces': {}}
Any idea what might be going on here?
kurtmckee commented
Please post the code you're using at the command line and the code you're writing and running in the Python file.
Please also post what version of feedparser is installed. Thanks!
kurtmckee commented
Closing due to lack of information.