A python module for parsing HTML into news components.
Project description
newsmeta
A python module for parsing HTML into news components.
Dependencies :globe_with_meridians:
- Python 3.7
- Newspaper3k 0.2.8
- BeautifulSoup 0.0.1
- Dateutil 2.8.2
- LangDetect 1.0.9
- Extruct 0.13.0
- DeepTranslator 1.5.4
- HTML5Lib 1.1
Installation :inbox_tray:
This is a python package hosted on pypi, so to install simply run the following command:
pip install newsmeta
Usage example :eyes:
In order to use this library simply feed it the downloaded HTML and the URL of the news piece, like so:
import newsmeta
with open("article.html") as article_fh:
article = newsmeta.parse(article_fh.read(), "http://www.article.com/article")
print(article.title)
License :memo:
The project is available under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
newsmeta-1.0.2.tar.gz
(5.1 kB
view details)
File details
Details for the file newsmeta-1.0.2.tar.gz
.
File metadata
- Download URL: newsmeta-1.0.2.tar.gz
- Upload date:
- Size: 5.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cb123b99ed334f81aa10d8858442e5720cf69752d24bfa592e3229c22ed7a12e |
|
MD5 | 562b75c2a76484b61b893adeeb0951b9 |
|
BLAKE2b-256 | 1294a93d52d55b8cbbf22d9e2aeadc4138481f1b40b14897f406b3aecf03beb1 |