Skip to content

I hate epoll! I hate epoll!

License

LGPL-3.0, GPL-3.0 licenses found

Licenses found

LGPL-3.0
LICENCE
GPL-3.0
LICENCE.GPL
Notifications You must be signed in to change notification settings

Fuyukai/Stickney

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Stickney

PyPI - Version

Stickney is an asynchronous websockets library for AnyIO and Python 3.11+. This is primarily designed for Trio (as asyncio is a bastard evil terrible library that deadlocks constantly) usage.

Installation

Stickney is available on PyPI.

$ poetry add stickney@latest

Usage

Create a new websocket with the open_ws_connection function:

async with open_ws_connection(url="wss:https://example.websocket.server/path?a=b") as ws:
    ...

You can send messages with the send_message function and receive messages with the receive_single_message function. You can also use close, but the WS is closed automatically when the context manager exits.

There's not really much else to it. See stickney/frames.py for the available message types.

Naming

Stickney is named after the Stickney crater on Phobos.

About

I hate epoll! I hate epoll!

Topics

Resources

License

LGPL-3.0, GPL-3.0 licenses found

Licenses found

LGPL-3.0
LICENCE
GPL-3.0
LICENCE.GPL

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages