How python-effect/effect works
Project type and purpose
• This is an open-source Python library (“Effect”) that provides a purely functional abstraction for handling side-effects (IO, state, async) via Intents, Effects, Dispatchers and Performers.
• It is not a full-stack app but a framework/tool you import into your Python projects to isolate and test side-effects.
File structure
• Top-level packaging and config:
• setup.py, setup.cfg, dev-requirements.txt, Makefile, .travis.yml ─ packaging, CI, linting and test harness
• docs/source ─ Sphinx docs and API reference
• effect/ ─ core library modules and tests
• Within effect/:
• _base.py, _dispatcher.py, _intents.py, _utils.py, etc. ─ core engine
• do.py, fold.py, io.py, parallel_async.py, ref.py, retry.py, threads.py ─ built-in effect Intents and combinators
• testing.py, _test_utils.py ─ testing helpers
• test_*.py ─ unit tests for each subsystem
README for additional insights
• Core concepts: Intent (any object), Effect wrapper, Dispatcher → Performer mapping, sync_perform entry point
• Emphasizes separation of “what” (Intent) from “how” (Performer)
• Supports sync, parallel-async, testers, retries, references
Diagramming recommendations
• Use UML Component or C4 Container notation: