-
Notifications
You must be signed in to change notification settings - Fork 48
PiPY Wheel Release Instructions
- Goals
- Creating a new wheel pre-release
- Check the github actions to make sure it runs to completion
- Initial verifying of the release:
- Create the Ready for Red Hat release
- Merge the release candidate into the release branch
- Create a new real release
- Check the github actions to make sure it runs to completion
- Make an artificatory release image
- Verifying the new real release
- Let people know on the slack channel that the release is ready
Every 2 weeks we can create a fms-hf-tuning pypi release:
Ability to test changes before push to main and before release
- pre-release candidate is created off the main branch, which allows us to test
- When we're ready to consider the release done, We sync the release branch with the release candidate tag
Then we create a release without the
rc#
convention.
Release branch that is stable and tested that RH pulls from
- ensure that this is using the release wheel with semver tag --> all using same commit
0.1 Need to be an admin in https://github.com/foundation-model-stack/fms-hf-tuning
0.2 Need to know what the next release will be... can check https://pypi.org/project/fms-hf-tuning/#history
1.1 Go to https://github.com/foundation-model-stack/fms-hf-tuning and on the lower right under "Releases" Click on "Draft a new release"
1.2 Click on "Choose a tag" and type in the new tag name. For example, v0.1.0-rc.1
and press "create tag on publish"
1.3 For the other items:
For release title, I'm using: v0.2.0-rc.1
For Target - Leave it at main
Click on "Generate Release notes"
Don't Click on "Set as the latest release"
Click on "Set as pre-release" button.
1.4 Click on Publish release
https://github.com/foundation-model-stack/fms-hf-tuning/actions
It should show up as available as a release on pypi here once complete: https://pypi.org/project/fms-hf-tuning/#history
3.1. See that you can clone the new tag:
git clone --branch <tag or release name> https://github.com/foundation-model-stack/fms-hf-tuning.git
for example:
git clone --branch v0.2.0-rc.1 https://github.com/foundation-model-stack/fms-hf-tuning.git
3.2. See if you can install the new pypi file:
Note: If you previously had fms-hf-tuning installed, you'll need to uninstall it: pip uninstall -y fms-hf-tuning
python -m venv .env
source .env/bin/activate
pip install --upgrade pip
pip install --pre fms-hf-tuning
and it should return the right version. For example:
pip list |grep fms
fms-hf-tuning 0.2.0rc1
Stop here and do the testing of the release candidate, which means making a rc-1 sft-trainer image and testing it. See Testing Instructions
If no changes have been made since the latest weekly integration test AND no additional models need to be tested for this release, you only need to ensure that tuning works on the release candidate image and can use the results from the integration test for our quality records.
For quality testing, follow along with and update Release Quality Records.
Step 4. Create the Ready for Red Hat release when the IBM release candidate testing is complete and we're ready to go:
Can be done in terminal with the following steps:
mkdir RELEASE ; cd RELEASE
git clone https://github.com/foundation-model-stack/fms-hf-tuning.git -b release
cd fms-hf-tuning
git checkout -b v0.2.0-rc1
git branch
git remote -v
git fetch --tags origin
git tag -l
git merge <tag_name> --signoff for example:
git merge v0.2.0-rc.1 --signoff
git push --set-upstream origin v0.2.0-rc1
Since release is a protected branch, make a pull request from your newly created branch into the release branch. Make sure someone approves your PR before you merge.
When you open your PR, a name example would be: release: merge set of changes for v0.2.0
NOTE: For release branch, do a regular merge commit, do not do a squash and merge into the release branch.
NOTE, in the unlikely event you have merge conflicts, this merge command would override any release changes with what you had tested from main:
git merge -X theirs <tag_name> for example:
git merge -X theirs v0.2.0-rc.1
5.1 Go to https://github.com/foundation-model-stack/fms-hf-tuning and on the lower right under "Releases" Click on "Draft a new release"
5.2 Click on "Choose a tag" and type in the new tag name. For example, v0.2.0
and press "create tag on publish"
5.3 For the other items:
For release title, I'm using: v0.2.0
For Target - Change it from main to release
Click on "Generate Release notes"
Click on "Set as the latest release" (If that option is there...)
5.4 Click on Publish release
https://github.com/foundation-model-stack/fms-hf-tuning/actions
It should show up as available as a release on pypi here once complete: https://pypi.org/project/fms-hf-tuning/#history
7.1 Clone or pull the latest copy of sft-trainer-image
git clone https://github.ibm.com/ai-foundation/sft-trainer-image.git
cd sft-trainer-image
7.2 make a new branch
git checkout -b release-v0.2.0
7.3 Clone the new tag into the sft-trainer repo:
git clone --branch v0.2.0 https://github.com/foundation-model-stack/fms-hf-tuning.git
7.4 git add the new folder with the right tag version of fms-hf-tuning
git add fms-hf-tuning
7.5 Commit it and push
git commit -sm "0.2.0 release for sft-trainer"
git push --set-upstream origin release-v0.2.0
7.6 Create a PR:
Make sure to merge into ai-foundations
for example:
ai-foundations/sft-trainer-image: main <- ai-foundations/sft-trainer-image: release-v0.2.0
Results in: https://github.ibm.com/ai-foundation/sft-trainer-image/pull/14
7.7 The interim image is created.
You can see it here: https://v3.travis.ibm.com/github/ai-foundation/sft-trainer-image/builds/20049215
It shows:
docker-na-private.artifactory.swg-devops.com/wcp-ai-foundation-team-docker-virtual/sft-trainer:release-v0.2.0_ubi9_py311
which should compute to:
docker-na-public.artifactory.swg-devops.com/wcp-ai-foundation-team-docker-virtual/sft-trainer:release-v0.2.0_ubi9_py311
7.8 Once the PR is merged, it'll result in an "official" release image. Can see that here:
https://v3.travis.ibm.com/github/ai-foundation/sft-trainer-image/builds/20051870
Which ended up with an image of:
docker-na-private.artifactory.swg-devops.com/wcp-ai-foundation-team-docker-virtual/sft-trainer:4304af0_ubi9_py311
which on the public side would be:
docker-na-public.artifactory.swg-devops.com/wcp-ai-foundation-team-docker-virtual/sft-trainer:4304af0_ubi9_py311
8.1. See that you can clone the new tag:
git clone --branch <tag or release name> https://github.com/foundation-model-stack/fms-hf-tuning.git
for example:
git clone --branch v0.2.0 https://github.com/foundation-model-stack/fms-hf-tuning.git
8.2. See if you can install the new pypi file:
python -m venv .env
source .env/bin/activate
pip install --upgrade pip
pip install fms-hf-tuning
and it should return the right version
pip list |grep fms
fms-hf-tuning 0.2.0
0.1.0: https://ibm-research.slack.com/archives/C0698T0FW3S/p1716242505819769 and 0.2.0 https://ibm-research.slack.com/archives/C0698T0FW3S/p1717112087215109