Skip to main content

A package for abstracting state machine logic

Project description

Python States

State Machines are great. Programming them isn't. python_states solves this issue by abstracting away all of the boilerplate emulation and transition handling. As a result, implementing a state machine is as simple as defining a state transition matrix and providing a starting state.

Usage

  1. Clone the repository:
git clone git@github.com:tedtasman/python_states.git
  1. Install dependencies with uv:
uv sync
  1. Run the project:
uv run python main.py

Future work

  1. Concurrent execution, which would add support for NFAs and other non-deterministic state machines
  2. Documentation...

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

python_states-0.2.0.tar.gz (2.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

python_states-0.2.0-py3-none-any.whl (4.9 kB view details)

Uploaded Python 3

File details

Details for the file python_states-0.2.0.tar.gz.

File metadata

  • Download URL: python_states-0.2.0.tar.gz
  • Upload date:
  • Size: 2.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for python_states-0.2.0.tar.gz
Algorithm Hash digest
SHA256 06abfe0ee992aef114c9a281363dbde1640f261c7b2910e05829f3ee7e0b5c23
MD5 5b0161eff3dc5272779dca84021da9c5
BLAKE2b-256 0234d9e98100a7565e3f848c5b12e997ffc5294d6d9a4bb6ab392ea585af350f

See more details on using hashes here.

File details

Details for the file python_states-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: python_states-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 4.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for python_states-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 31efafb4136a441c4e19f306826f0a30b000c3f92a789dc4a5edfb79ff1de7df
MD5 8c3d1f8887db05ae8d9c38944adc45ee
BLAKE2b-256 dbbcf501b755f4c1572fbe1754928ed1edfec30be636367c7d7dd76f98d66a5b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page