A minimal feed reader library.
Project description
reader is a Python feed reader library.
reader can be used to retrieve, store, and manage Atom and RSS feeds. It is designed to allow writing feed reader applications without any business code, and without enforcing a dependency on a particular framework.
Features:
Stand-alone library with stable, clearly documented API, and excellent test coverage.
Full-text search.
Minimal web interface that works even with text-only browsers.
… with automatic tag fixing for podcasts (MP3 enclosures).
(Some) plugin support.
Documentation: reader.readthedocs.io
Usage:
$ pip install reader[search]
>>> from reader import make_reader
>>>
>>> reader = make_reader('db.sqlite')
>>> reader.add_feed('http://www.hellointernet.fm/podcast?format=rss')
>>> reader.update_feeds()
>>>
>>> entries = list(reader.get_entries())
>>> [e.title for e in entries]
['H.I. #108: Project Cyclops', 'H.I. #107: One Year of Weird', ...]
>>>
>>> reader.mark_as_read(entries[0])
>>>
>>> [e.title for e in reader.get_entries(read=False)]
['H.I. #107: One Year of Weird', 'H.I. #106: Water on Mars', ...]
>>> [e.title for e in reader.get_entries(read=True)]
['H.I. #108: Project Cyclops']
>>>
>>> reader.enable_search()
>>> reader.update_search()
>>>
>>> for e in list(reader.search_entries('year'))[:3]:
... title = e.metadata.get('.title')
... print(title.value, title.highlights)
...
H.I. #107: One Year of Weird (slice(15, 19, None),)
H.I. #52: 20,000 Years of Torment (slice(17, 22, None),)
H.I. #83: The Best Kind of Prison ()
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file reader-1.0.1.tar.gz.
File metadata
- Download URL: reader-1.0.1.tar.gz
- Upload date:
- Size: 1.5 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
70bd8b084f9a7a302d5dfedb43a4b9f559f26ef9ea1a6e875f0028557f9ad9ae
|
|
| MD5 |
3aee174788a3423e7899ed7e7677264b
|
|
| BLAKE2b-256 |
aceeadb7d65a10f0330ea345e49876c98660d3e20a59f622ef9a630de1c95bc4
|
File details
Details for the file reader-1.0.1-py3-none-any.whl.
File metadata
- Download URL: reader-1.0.1-py3-none-any.whl
- Upload date:
- Size: 64.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.7.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3eddc06b2cb54e245dedf8f2596834fc1305ec521e9527e108a79837914944c5
|
|
| MD5 |
7fafe72dcd2d66fe6bb4114cb9133072
|
|
| BLAKE2b-256 |
43966eb1d9c5dca17bc64b25ca1b533c43593dc9a751ba5a599a6f91fb6fab9b
|