Konsensus
A simple clustering by consensus library in Python. This is a simple implementation of a replicated state machine using a Paxos-derived algorithm.
Getting Started
Ensure you have the following first before you proceed:
-
You will require Python 3.10+ to run this project. If you are using a different version of Python, you will need to update your Python version to 3.10+. You can check your Python version by running
python --versionin your terminal. There are ways to install different versions of Python on your system and this can be done using pyenv. -
Poetry is a Python package manager that is used to manage dependencies. You can check the installation instructions in the link provided to get this setup.
-
Not a hard requirement as poetry should setup a virtual environment for you, but can be used as well to setup a virtual environment.
Once you have dependencies setup, run the below command to install dependencies:
poetry install
Even though this implementation has 0 dependencies to external packages, the dev packages are used for linting & handling tests. Therefore, this is useful when running linting & test commands.
The library itself is in the konsensus directory.
Running
There is a simple script in the project root run.py that contains a sample setup on how to use the library. It can be run with:
python run.py 10
10 is the seed value, this can be any other value like 20 or 30, etc
There are other scripts available in the Makefile that can be used to run formatting, linting, test or build commands.
Built With
| Tool | Purpose |
|---|---|
| Python | Programming Language |
| Poetry | Dependency & Package manager |
Contributing
Please read the contributing guide to learn how to contribute to this project.
Versioning
Semantic versioning is used to track the version of the project.
Metadata
Release files for konsensus 0.1.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| konsensus-0.1.4.tar.gz | 13.8 kB | Without provenance | Details for konsensus-0.1.4.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| konsensus-0.1.4-py3-none-any.whl | Python 3 | none | any | Details for konsensus-0.1.4-py3-none-any.whl |
Total release size: 33.2 kB
Release files / konsensus-0.1.4.tar.gz
| Download URL | konsensus-0.1.4.tar.gz |
|---|---|
| Size | 13.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b0e7b4c2475d5dbe4007c85d7f383d7d00cdb9cb0a77cd68aa17277df01c39b0
|
|
BLAKE2b-256 checksum How to use checksums |
311f96cb583501d287159484aa4a96f294617952bdce9637706751b952602fcf
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.10.10
|
Release files / konsensus-0.1.4-py3-none-any.whl
| Download URL | konsensus-0.1.4-py3-none-any.whl |
|---|---|
| Size | 19.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
28399e0515ab8fb8f6ff41a5fd7249b99878678df0912db49a376a9486e776ad
|
|
BLAKE2b-256 checksum How to use checksums |
a018976487f3ef85d4c91c2014d1baf1f1436818ce8bfb3d83336dfed455f0f0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.10.10
|
Security for konsensus 0.1.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.