microsoft / responsible-ai-toolbox-mitigations

Python library for implementing Responsible AI mitigations.
https://responsible-ai-toolbox-mitigations.readthedocs.io/en/latest/
MIT License
57 stars 6 forks source link

Mmendonca/new auto bump #21

Closed mrfmendonca closed 2 years ago

mrfmendonca commented 2 years ago

This PR updates the way the version is auto-bumped in the "release-pypi.yml" workflow. The aim is to allow 4 types of bumps, instead of only 3:

This way, we can create pip packages using pre-release versions, and send it to test.pypi. If the package has any problems, this won't be an issue, as it's only a pre-release version that was sent to test.pypi. When we get the package to work, we can then do a real bump (major, minor, or patch), send it to test.pypi again, and only then send it to pypi.

This PR stops using the bump2version package (that was being used in release-pypi.yml) and starts using the semver python package. For this, I removed the .bumpversion.cfg file that was used by bump2version, and added the bump_version.py script that I created to bump the version automatically using semver.

Another point is regarding git tags. Read the Docs uses git tags to determine different versions of the documentation: one doc for each different release. Each release is saved using git tags. Therefore, after bumping the version, I'm also creating a git tag with the new version of the package. This is all done automatically and will work with Read the Docs when it's configured (Read the Docs only works for public repos, so that's why it isn't configured yet).

codecov[bot] commented 2 years ago

The author of this PR, mrfmendonca, is not an activated member of this organization on Codecov. Please activate this user on Codecov to display this PR comment. Coverage data is still being uploaded to Codecov.io for purposes of overall coverage calculations. Please don't hesitate to email us at support@codecov.io with any questions.