Skip to content

newspaper4k not working with PyInstaller #675

@martinrotter

Description

@martinrotter

I have sample script:

from newspaper import Article

url = 'https://www.root.cz/zpravicky/freebsd-ma-plne-reprodukovatelne-buildy/'
article = Article(url)

article.download()
article.parse()

print(article.text)

The script works without any problems. When trying to package it with pyinstaller and running output bundled binary, I get this error:


    ^
  File "newspaper\article.py", line 485, in parse
  File "newspaper\extractors\content_extractor.py", line 167, in calculate_best_node
  File "newspaper\extractors\articlebody_extractor.py", line 41, in parse
  File "newspaper\text.py", line 122, in __init__
FileNotFoundError: Stopwords file for language en not found! Make sure that the language is supported (see `

newspaper.languages()`)

Do you as newspaper4k have any quick tips to deal with this error? Many thanks.

Metadata

Metadata

Labels

help wantedExtra attention is needed

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions