Typed pythonic RSS parser
Project description
Rss parser
About
rss-parser
is typed python RSS parsing module built using BeautifulSoup
and pydantic
Installation
pip install rss-parser
or
git clone https://github.com/dhvcc/rss-parser.git
cd rss-parser
pip install .
Usage
from rss_parser import Parser
from requests import get
rss_url = "https://feedforall.com/sample.xml"
xml = get(rss_url)
# Limit feed output to 5 items
# To disable limit simply do not provide the argument or use None
parser = Parser(xml=xml.content, limit=5)
feed = parser.parse()
# Print out feed meta data
print(feed.language)
print(feed.version)
# Iteratively print feed items
for item in feed.feed:
print(item.title)
print(item.description)
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Install dependencies with poetry install
(pip install poetry
)
pre-commit
usage is highly recommended. To install hooks run
poetry run pre-commit install -t=pre-commit -t=pre-push
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
rss-parser-0.2.3.tar.gz
(16.3 kB
view hashes)
Built Distribution
rss_parser-0.2.3-py3-none-any.whl
(16.2 kB
view hashes)
Close
Hashes for rss_parser-0.2.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c2f01cec96e6da36b8cdb18d7b114444ca05a02b53e640f6877cde4a135dba39 |
|
MD5 | d06cfe61c508204bf40e6060e72f17fd |
|
BLAKE2b-256 | 689c2593d0fbdf1f24d3a33fe65c6bfe399a0370b0e9254ccf6dbae514849988 |