Tooling and Conventions

TinyFlux should be developed locally with the latest stable version of Python on any platform (3.10 as of this writing).

Versioning

TinyFlux follows semantic versioning guidelines for releases.

Workflow

TinyFlux development follows the branch-based workflow known as “GitHub flow”.

Continuous Integration and Deployment

TinyFlux uses GitHub Actions for its CI/CD workflow.

Coding Conventions

TinyFlux conforms to PEP 8 for style, and Google Python Style Guide for docstrings. TinyFlux uses common developer tools to check and enforce this. These checks should be performed locally before pushing to GitHub, as they will eventually be enforced with GitHub Actions (see .github/workflows in the TinyFlux GitHub repository for details).

Formatting

TinyFlux uses standard configuration black for code formatting, with an enforced line-length of 80 characters.

After installing the project requirements:

/tinyflux $ black .

Style

TinyFlux uses standard configuration flake8 for style enforcement, with an enforced line-length of 80 characters.

After installing the project requirements:

/tinyflux $ flake8 .

Typing

TinyFlux uses standard configuration mypy for static type checking.

After installing the project requirements:

/tinyflux $ mypy .

Documentation

TinyFlux hosts documentation on Read The Docs.

TinyFlux uses Sphinx for documentation generation, with a customized Read the Docs Sphinx Theme, enabled for “Google-style” docstrings.

After installing the project requirements:

/tinyflux $ cd docs
/docs $ make html
/docs $ open build/html/index.html

Documentation is deployed to ReadTheDocs through third-party integration with GitHub. Commits to the master branch trigger builds and deployment with RTD.

Testing

TinyFlux aims for 100% code coverage through unit testing.

Test Framework

TinyFlux uses pytest as its testing framework.

After installing the project requirements:

/tinyflux $ pytest

Coverage

TinyFlux uses Coverage.py for measuring code coverage.

/tinyflux $ coverage run -m pytest
/tinyflux $ coverage report -m