Skip to content

Commit

Permalink
Update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeshardmind committed Jan 15, 2025
1 parent 5d67363 commit 81d3b7e
Showing 1 changed file with 71 additions and 6 deletions.
77 changes: 71 additions & 6 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@

This contains various async utility functions I've written

# Documentation

Things now have initial documentation, but no rendered docs site, examples, or
prose yet.

# Design goals

## The obvious use should be correct
Expand Down Expand Up @@ -35,4 +30,74 @@ This includes:

There's not much further to say about this goal right now, but this
should be expanded on later in the WIP accompanying guide on making
concurrent systems written in python fault tolerant at scale.
concurrent systems written in python fault tolerant at scale.

# Documentation

Most things now have initial documentation, but no rendered docs site, examples, or
prose yet.

What's in each public export, below

## bg_loop.py

Contains a context manager that creates an asyncio event loop in a backgrouns thread and wraps
scheduling to it,

## bg_tasks.py

Contains a lightweight alternative to asyncio TaskGroups, without the entertwined cancellation semantics.

## corofunc_cache.py

Contains lightweight preemptive async caching decorators

## dual_color.py

Note: missing docs

Contains thread-safe queues and a thread-safe semaphore
with both sync and async colored access.

## gen_transform.py

Contains a function to wrap a synchronous generator in a thread use it asynchronously

## lockout.py

async digital loto tags!

## lru.py

A lightweight lru-cache mapping

## priority_sem.py

A priority semaphore.

## ratelimiter.py

A ratelimiting context manager.

## scheduler.py

A simple in-memory asyncio job runner.

## sig_service.py

Note: This needs much better examples and documentation

A means of abstracting signal handling for graceful shutdown
in multi-color concurrent applications

## task_cache.py

Note: This pulls in inspect, see `corofunc_cache.py` for the lightweight
alternative if you don't need direct access to the lower level task objects.

task-based decorators for preemptive async caching.

## waterfall.py

an async batching mechanism that dispatches by volume or time interval,
whichever is satisfied first.

0 comments on commit 81d3b7e

Please sign in to comment.