Skip to content

newspaper.build( ) error #111

Description

@adeze

Hi, when i try to test with the quick start example

>>> import newspaper

>>> cnn_paper = newspaper.build('http://cnn.com')

>>> for article in cnn_paper.articles:
>>>     print(article.url)

i get an error

Traceback (most recent call last):

  File "<ipython-input-23-f22cd7df4cac>", line 3, in <module>
    cnn_paper = newspaper.build('http://cnn.com')

  File "/Users/Adam/anaconda/lib/python3.4/site-packages/newspaper/api.py", line 31, in build
    s.build()

  File "/Users/Adam/anaconda/lib/python3.4/site-packages/newspaper/source.py", line 92, in build
    self.download(response)

TypeError: download() takes 1 positional argument but 2 were given

i'm using spyder(python 3.4) through anaconda if that makes a different, but getting an article directly works OK. I'm fairly new to python, so is there something i'm missing?
thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions