Do not allow prints in your code
Project description
Check Bump
About
Want to add version bump checks to your CI/CD pipeline? This packages makes it easy.
Simply execute check-vbump
within a directory where your pyproject.toml
is located.
If there was a version bump, process will finish with exit code 0 - read stdout for the new version. Otherwise, process will finish with exit code 1.
Requirements
This package requires tomlkit
package.
Usage
Simply execute check-bump
within a directory where your pyproject.toml
is located. Or provide a path using --path
argument.
user$ check-bump --help
usage: check-bump [-h] [-p PATH]
Detect and retrieve version bump
options:
-h, --help show this help message and exit
-p PATH, --path PATH path to pyproject.toml file
Development
Installation
Install virtual environment and check_bump package in editable mode with dev dependencies.
python -m venv venv
source venv/bin/activate
pip install -e .[dev]
Formatting
Use black and isort (with black profile) to format the code.
isort .
black .
Syntax checks
Use pylint to check the code for errors and potential problems. Also use noprint to detect print statements in the code (use logging instead!).
isort -c .
black --check .
pylint check_bump tests
noprint -ve check_bump tests
Testing
For testing use coverage with pytest workers - this is due to errors that pytest-cov sometimes has with Python 3.9 and above.
coverage run -m pytest -xv tests
coverage report -m --fail-under=30
coverage erase
Clean up
Clean up the project directory from temporary files and directories. Purge virual environment.
coverage erase
rm -rf check_bump.egg-info/ dist/ build/
rm -rf venv/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for check_bump-1.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 16b03d6ba462bd216ea5540af0b778442565b23eb9c4f308842cc05c65d0ee47 |
|
MD5 | 86378a7b3d293a6733912a8f60df5c0f |
|
BLAKE2b-256 | 8f4f79429cfc3ccfedd5e6576bb683b862a36d8ae64d4c83921ee9afffe1c51f |