Skip to content

Latest commit

 

History

History
94 lines (67 loc) · 1.76 KB

CONTRIBUTING.md

File metadata and controls

94 lines (67 loc) · 1.76 KB

Development and Testing

Primary Development Commands

To check and resolve linting issues in the codebase, run:

poetry run ruff check --fix

To check and resolve formatting issues in the codebase, run:

poetry run ruff format

To check the unit tests in the codebase, run:

poetry run pytest

To check the typing in the codebase, run:

poetry run mypy

To generate a code coverage report after testing locally, run:

poetry run coverage html

To check the lock file is up-to-date:

poetry check --lock

Shortcut Task Commands

To be able to run shortcut task commands, first install the Poetry plugin poethepoet:

poetry self add 'poethepoet[poetry_plugin]'

Note

Upon the release of Poetry v2.0.0, Poetry will automatically support bootstrap installation of project-specific plugins and installation of the task runner will become automatic for this project. The pyproject.toml syntax will be:

[tool.poetry]
requires-poetry = ">=2.0"

[tool.poetry.requires-plugins]
poethepoet = ">=0.29"

For Running Individual Checks

poetry task check-lock
poetry task check-format
poetry task check-lint
poetry task check-tests
poetry task check-typing

For Running All Checks

poetry task check-all

For Running Individual Fixes

poetry task fix-format
poetry task fix-lint

For Running All Fixes

poetry task fix-all

For Running All Fixes and Checks

poetry task fix-and-check-all