codelucas / newspaper

newspaper3k is a news, full-text, and article metadata extraction in Python 3. Advanced docs:
https://goo.gl/VX41yK
MIT License
13.89k stars 2.1k forks source link

Parsing Problem #971

Closed skittoo closed 1 year ago

skittoo commented 1 year ago

for this link: https://www.cnn.com/2023/06/24/us/how-much-lake-mead-water-rise-climate/index.html no parsing output!

johnbumgarner commented 1 year ago

Can you provide your code?

skittoo commented 1 year ago

Can you provide your code?

from newspaper import Article

url = 'https://www.cnn.com/2023/06/24/us/how-much-lake-mead-water-rise-climate/index.html'

article = Article(url)

article.download()

article.parse()

print(article.authors)

print(article.publish_date)

print(article.text)

print(article.top_image)

johnbumgarner commented 1 year ago

Thanks for sharing your code. Please take a look at the CNN extraction example in my repository on newspaper3 usage. I tested my example code with your URL and it works. If you have any additional questions about newspaper3 usage please open an issue in my repository and I will see what I can do to help.

skittoo commented 1 year ago

Thank you

Thanks for sharing your code. Please take a look at the CNN extraction example in my repository on newspaper3 usage. I tested my example code with your URL and it works. If you have any additional questions about newspaper3 usage please open an issue in my repository and I will see what I can do to help.

Thanks ! This was really helpful <3

johnbumgarner commented 1 year ago

You're welcome. Remember to close this issue on this repository, because I check the issues and have no way to close them when they are resolved.

skittoo commented 1 year ago

Sure