A Server-Sent Event python client base on aiohttp
Project description
SSE Client
A Server-Sent Event python client base on aiohttp, provides a simple interface to process Server-Sent Event.
Free software: Apache Software License 2.0
Documentation: https://aiohttp-sse-client.readthedocs.io.
Features
Full asyncio support
Easy to integrate with other aiohttp based project
Auto-reconnect for network issue
Support python 3.5.3 and above
Usage
from aiohttp_sse_client import client as sse_client
async with sse_client.EventSource(
'https://stream.wikimedia.org/v2/stream/recentchange'
) as event_source:
try:
async for event in event_source:
print(event)
except ConnectionError:
pass
Credits
This project was inspired by aiosseclient, sseclient, and sseclient-py.
This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.
History
0.1.4 (2018-10-04)
Switch to Apache Software License 2.0
0.1.3 (2018-10-03)
Change the error handling, better fit the live specification.
0.1.2 (2018-10-03)
Implement auto-reconnect feature.
0.1.1 (2018-10-02)
First release on PyPI.
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
Hashes for aiohttp_sse_client-0.1.4-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 468ce4e1120b896d37141d8f9d235fd58212c8024a909ec88c20ce143253cebd |
|
MD5 | ced23010b91c541eb482a5a9e858e4d9 |
|
BLAKE2b-256 | 4f742758bf0265a1bcc70244edccdff5e4e91c76da4a80b44b7ef3906f5216f7 |