To test the codebase, run the following command:
poetry run pytestThe command will:
- Execute unit tests with
pytest - Test the language typing with
mypy - Test for linting and styling errors with
ruff - Emit a testing coverage report with
coverage
To format the code in the library, run the following commands:
poetry run ruff check --select I --fix
poetry run ruff format longplexpy testsTo generate a code coverage report locally, run the following command:
poetry run coverage htmlThe docker image can be built by running:
ci/docker-build-image- Navigate to the Trigger Version Bump Action.
- Select "Run Workflow" and enter a new version of the form "#.#.#". Ensure the new version is higher than the current version. See Semantic Versioning for help selecting the next version.
- The trigger version bump action will open a new PR with a title similar to "chore(#.#.#): update pyproject version"
- Perform a squash merge on this PR to commit the version bump to main
- In your local repository, checkout main, pull the latest changes, add and push the release tag.
git checkout main git pull git tag -a "#.#.#" -m "Release #.#.#" git push --tags
- If completed successfully, a new tag matching the "#.#.#" pattern should have been added to main. You can check the tags page. This will trigger the Create Release Action.
- If the jobs completed successfully, there should also be a new release on the releases page.
- Navigate to Build and Deploy Action
- You should see two workflow runs with titles similar to the PR title, "chore(#.#.#): update pyproject version".
One should have a triggering event as the new tag "#.#.#" and one should have a triggering event as
main. - A green checkmark on these actions indicates the docker image was built, tagged, and pushed to the seqwell/longplexpy repo on Dockerhub.