Commands needed for setting up a development environment and running tests
python3 -m venv venv
source ./venv/bin/activate
python3 -m pip install --editable '.[dev,numpy]'
The package must be installed to be tested because the C library must be compiled and this is done during packaging.
python3 -m pip install pytest
pytest
pytest README.md
pytest --cov=pymseed --cov-report=term-missing --cov-report=html --cov-report=xml
pytest --cov=pymseed --cov-report=html && open htmlcov/index.html
The single-source package version is specified in: src/pymseed/version.py
The versioning follows the semantic versioning definition.
For maintainers publishing releases, install the release dependencies: pip install pymseed[release]
This provides build and twine for package building and PyPI publishing.
Distributions are built automatically by a GitHub Action when a release is created.
The Action has a workflow_dispatch trigger that allows manually triggering of the build process from here: https://github.com/EarthScope/pymseed/actions/workflows/release.yml
This is convenient for testing the build process prior to creating a new release. These wheels will not be published to PyPI, that only happens for releases created on github.com
gh workflow run BuildRelease --ref
python3 -m pip install build twine
python3 -m build
Official releases should be built by the GitHub Action, this is only needed in special cases, or more likely nevermore.
python3 -m twine check --strict dist/* python3 -m twine upload dist/*