-
Notifications
You must be signed in to change notification settings - Fork 93
Release procedure
The pyfakefs package is released on PyPi.
This article shows how to prepare a release for pyfakefs (for pypi package maintainers or contributors only).
Decide on a new version "M.mm.pp" according to semantic versioning.
On your local computer, clone or pull branch main of pyfakefs. Check out a new branch version-M.mm
:
git checkout -b version-M.mm.pp
Edit CHANGES.md
with descriptions of the new features and bug fixes.
Make sure that pyfakefs/_version.py
attribute __version__
is the correct version number:
__version__ = 'M.mm.pp'
Make sure that pyfakefs/docs/conf.py
attributes version
and release
are set correctly:
version = 'M.mm.pp'
release = 'M.mm.pp'
If needed, also adapt the year in the copyright
attribute.
Run the tests:
./all_tests.py
Git add, commit.
Push your branch to GitHub:
git push --set-upstream origin version-M.mm.pp
Wait until all tests in GitHub Actions are passed.
Go to the pyfakefs project on github.com. Create a Pull Request for your release branch.
Wait for GitHub Actions to say your pull request passes the tests.
After the tests pass, accept the merge request. Do not delete the branch.
Return to your local computer.
On GitHub, go to Release.
Create a version tag of the format vM.mm.pp
, where M.mm.pp is the version number.
Choose the previously release branch version-M.mm.pp
.
Explain the contents of the release, and release it!
After the release, the release-deploy workflow is triggered, that will create a release on PyPI and create the release documentation. Wait until the worklow is finished and check for any problems.
Return to branch main:
git checkout main
git pull
Edit pyfakefs/fake_filesystem.py
attribute __version__
with the new version number M.nn.dev0, where nn=mm+1:
__version__ = 'M.nn.dev0'
Edit pyfakefs/docs/conf.py
attributes version
and release
accordingly:
version = 'M.nn'
release = 'M.nn.dev'
Edit CHANGES.md
, add an entry for the upcoming release:
## Unreleased