Skip to content

Commit

Permalink
Fix version_suffix passing in build_packages.yml.
Browse files Browse the repository at this point in the history
  • Loading branch information
ScottTodd committed Dec 9, 2024
1 parent 217690e commit 0ae1e75
Showing 1 changed file with 9 additions and 10 deletions.
19 changes: 9 additions & 10 deletions .github/workflows/build_packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,26 +23,25 @@ jobs:
if: ${{ github.repository_owner == 'nod-ai' || github.event_name != 'schedule' }}
runs-on: ubuntu-24.04
outputs:
shark_package_version: ${{ steps.version.outputs.shark_package_version }}
version_suffix: ${{ steps.version_rc.outputs.version_suffix }}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Setup Python
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
with:
python-version: 3.12
cache: "pip"

- name: Install Python packages
run: |
pip install packaging
pip freeze
run: pip install packaging

- name: Generate release candidate versions
id: version_rc
run: |
version_suffix="$(printf 'rc%(%Y%m%d)T')"
echo "version_suffix=${version_suffix}" >> $GITHUB_ENV
sharktank_package_version=$(python3 build_tools/python_deploy/compute_local_version.py --version-suffix=${version_suffix} sharktank)
shortfin_package_version=$(python3 build_tools/python_deploy/compute_local_version.py --version-suffix=${version_suffix} shortfin)
sharkai_package_version=$(python3 build_tools/python_deploy/compute_common_version.py -rc --version-suffix=${version_suffix} --write-json)
echo "version_suffix=${version_suffix}" >> $GITHUB_OUTPUT
python3 build_tools/python_deploy/compute_local_version.py --version-suffix=${version_suffix} sharktank
python3 build_tools/python_deploy/compute_local_version.py --version-suffix=${version_suffix} shortfin
python3 build_tools/python_deploy/compute_common_version.py -rc --version-suffix=${version_suffix} --write-json
- name: Upload version_local.json
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
Expand Down Expand Up @@ -115,7 +114,7 @@ jobs:
OUTPUT_DIR: "${{ github.workspace }}/bindist"
run: |
[ -e ./bindist/* ] && rm ./bindist/*
./c/build_tools/python_deploy/write_requirements.py --version-suffix=${version_suffix}
./c/build_tools/python_deploy/write_requirements.py --version-suffix=${{ needs.setup_metadata.outputs.version_suffix }}
./c/shark-ai/build_tools/build_linux_package.sh
- name: Build sharktank (Linux x86_64)
Expand Down

0 comments on commit 0ae1e75

Please sign in to comment.