pybeehive

A lightweight, event-driven concurrency library with bees!


Keywords
pybeehive
License
GPL-3.0
Install
pip install pybeehive==0.1.4

Documentation

pybeehive

Documentation Status Updates

A lightweight, event-driven concurrency library with bees!

Features

  • One interface for writing concurrent code, both sync and async

Basic Usage

from pybeehive import Hive
import time
hive = Hive()

@hive.streamer
def stream():
    while True:
        time.sleep(1)
        yield 'hello world!'

@hive.listener
def on_event(event):
    print(event)

if __name__ == '__main__':
    hive.run()
$ python hello.py
Event(created_at=1525400000, data="hello world!")
Event(created_at=1525400001, data="hello world!")
Event(created_at=1525400002, data="hello world!")
...

Credits

This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.