Installation and Developer's Documentation¶
Recommended Installation¶
The package prymer requires installation of Primer3 and interactive bwa.
To satisfy these requirements, it is recommended to install using bioconda:
Installation for Development and Release¶
- Install the environment manager
mamba - Install the Python build tool
poetry -
Create an environment with Python, Primer3, and interactive
bwa: -
Activate the environment:
-
Configure
poetryto install into pre-existing virtual environments: -
Install
prymerinto the virtual environment:
Checking the Build¶
Use poetry to test your code.
Note that poetry run pytest will run mypy checks, ruff checks, pytest unit tests, and will provide a unit test coverage report.
However, pytest will neither run the ruff formatter nor apply ruff's automatic lint fixes, which can be done by calling ruff directly.
Building the Documentation¶
Use mkdocs to build and serve the documentation.
Creating a Release on PyPi¶
- Clone the repository recursively and ensure you are on the
main(un-dirty) branch - Checkout a new branch to prepare the library for release
- Bump the version of the library to the desired SemVer with
poetry version #.#.# - Commit the version bump changes with a Git commit message like
chore(release): bump to #.#.# - Push the commit to the upstream remote, open a PR, ensure tests pass, and seek reviews
- Squash merge the PR
- Tag the new commit on the main branch of the origin repository with the new SemVer
[!NOTE] This project follows Semantic Versioning. In brief:
MAJORversion when you make incompatible API changesMINORversion when you add functionality in a backwards compatible mannerPATCHversion when you make backwards compatible bug fixes
GitHub Actions will take care of the remainder of the deployment and release process with:
- Unit tests will be run for safety-sake
- A source distribution will be built
- Multi-arch multi-Python binary distributions will be built
- Assets will be deployed to PyPi with the new SemVer
- A Conventional Commit-aware changelog will be drafted
- A GitHub release will be created with the new SemVer and the drafted changelog
[!IMPORTANT] Consider editing the changelog if there are any errors or necessary enhancements.