<commit_before># photon-pump
A TCP eventstore client in Python 3.6

```python
async def write_an_event():
    async with photonpump.connect() as conn:
        await conn.publish_event('pony.jumped', body={
            'name': 'Applejack',
            'height_m': 0.6
        })
```<commit_msg>More spurious examples.<commit_after># photon-pump
A TCP eventstore client in Python 3.6

```python
async def write_an_event():
    async with photonpump.connect() as conn:
        await conn.publish_event('pony_stream', 'pony.jumped', body={
            'name': 'Applejack',
            'height_m': 0.6
        })


async def read_an_event(conn):
    event = await conn.get_event('pony_stream', 1)
    print(event)


async def ticker(delay, to):
    for i in range(to):
        yield NewEvent('tick', body{ 'tick': i})
        await asyncio.sleep(delay)


async def write_an_infinite_number_of_events(conn):
    await conn.publish('ticker_stream', ticker(1000))


async def read_an_infinite_number_of_events(conn):
    async for event in conn.stream('ticker_stream'):
        print(event)
```
{'fraction_non_alphanumeric': 0.1252302025782689, 'fraction_numerical': 0.011970534069981584, 'mean_word_length': 3.279527559055118, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2030955', 'n_tokens_mistral': 371, 'n_tokens_neox': 351, 'n_words': 91}