From 677b9786d7cf3f87295ab9ab74d801f24808e9c9 Mon Sep 17 00:00:00 2001 From: Andrei Paraschiv Date: Wed, 17 Jan 2024 01:06:28 +0200 Subject: [PATCH] Fix typos in documentation * feat(doc): :memo: adding evaluation results * feat(doc): :rocket: Documentation Update. Added Examples, documented new features --- CONTRIBUTING.md | 4 ++-- README.md | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 9147e45..9859259 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -126,8 +126,8 @@ source venv/bin/activate # Upgrade pip (very important!) pip install --upgrade pip -# Install Newspaper3k in editable mode -pip install -e '.[dev]' +# Install Newspaper4k in editable mode +pip install -e '.' ``` Last, install the pre-commit hooks with: diff --git a/README.md b/README.md index d91b660..ba7dc40 100755 --- a/README.md +++ b/README.md @@ -85,6 +85,7 @@ import newspaper cnn_paper = newspaper.build('http://cnn.com', number_threads=3) print(cnn_paper.category_urls()) + # ['https://cnn.com', 'https://money.cnn.com', 'https://arabic.cnn.com', # 'https://cnnespanol.cnn.com', 'http://edition.cnn.com', # 'https://edition.cnn.com', 'https://us.cnn.com', 'https://www.cnn.com'] @@ -95,6 +96,7 @@ print(article_urls[:3]) # 'https://arabic.cnn.com/middle-east/video/2023/10/30/v146619-sotu-sullivan-hostage-negotiations', # 'https://arabic.cnn.com/middle-east/article/2023/10/29/norwegian-pm-israel-gaza'] + article = cnn_paper.articles[0] article.download() article.parse()