Skip to content

sbtinstruments/cyto

Repository files navigation

Cyto 🦠

Idiomatic boilerplate and glue code for Python

Cyto is the bridge between an oppinionated selection of Python tech. Cyto is everything you need to create a modern Python app. Cyto is the glue and boilerplate code that you no longer have to write yourself.

Note 2024-08-21: pydantic-settings now supports auto-generation of a CLI based on a pydantic model. Therefore, cyto no longer includes this feature.

Only pay for what you use

Cyto has zero dependencies per default. Opt-in to functionality via extras.

Installation

Install Cyto along with all extras:

pip install cyto[all]

Poetry has a specific --all-extras option to help you out:

poetry add cyto --all-extras

Choose specific extras

If you only want a specific extra, choose that when you install Cyto. E.g.:

pip install cyto[settings]  # Automatically pulls in pydantic-settings

Similar for poetry:

poetry add cyto[settings]  # Automatically pulls in pydantic-settings

Development

Python Version

Development requires Python 3.12 or later. Test your python version with:

python3 --version

If you have multiple python installations, you can replace python3 with a specific version (e.g., python3.12) in the steps below.

Getting Started

Do the following:

  1. Clone this repository
    git clone git@github.com:sbtinstruments/cyto.git
  2. Install poetry (for dependency management)
    curl -sSL https://install.python-poetry.org | python3
  3. Create poetry's virtual environment and get all dependencies and all extra features.
    poetry install --extras all

Quality Assurance (QA) Tools

QA Basic Tools

All QA basic tools automatically run in Jenkins for each commit pushed to the remote repository.

The QA basic tools are:

  • ruff
  • mypy

You can run the QA basic tools manually. This is useful if you don't want to install the pre-commit hooks.

Run the QA basic tools manually with:

poetry run task ruff
poetry run task mypy

QA Test Tools

All of the tools below automatically run in Jenkins for each commit pushed to the remote repository.

The QA test tools are:

  • pytest (the test framework itself)
  • pytest-cov (for test coverage percentage)

Visual Studio Code

Settings

We have a default settings file that you can use via the following command:

cp .vscode/settings.json.default .vscode/settings.json

This is optional.

About

Idiomatic boilerplate and glue code for Python

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages