diff --git a/.github/workflows/build-wheels.yml b/.github/workflows/build-wheels.yml index 6a3f67845..86cd89bfe 100644 --- a/.github/workflows/build-wheels.yml +++ b/.github/workflows/build-wheels.yml @@ -1,7 +1,7 @@ name: Ion-python release on: - push: # TODO change it to push and enable tags + push: branches: [ master wheels ] tags: - "v*.*.*" @@ -23,32 +23,9 @@ jobs: - name: Create a virtual environment run: git submodule init && git submodule update && python3 -m venv ./venv && . venv/bin/activate -# - run: pip install -r requirements.txt -# - run: pip install -e . -# - run: py.test -# pip install -i https://test.pypi.org/simple/ amazon.ion== - - name: fetch wheels - run: | - for (( i=0; i<3; i++ )) - do - v="" - pip install amazon.ion==${GITHUB_REF##*/v} || true - v=$( pip show amazon.ion | grep Version ) - - if [[ $v == "Version: ${GITHUB_REF##*/v}" ]] - then - echo "Found desired version: $v" - break - fi - - sleep 5s - done - - if [[ $v != "Version: ${GITHUB_REF##*/v}" ]] - then - echo "Exiting because unable to install the new version from PYPI" - exit 1 - fi + - run: pip install -r requirements.txt + - run: pip install -e . + - run: py.test build-source: if: startsWith(github.ref, 'refs/tags/') @@ -97,7 +74,7 @@ jobs: fail-fast: false # TODO change it back to True matrix: python-version: [ '3.10'] - os: [ubuntu-latest, windows-latest, macos-latest] + os: [windows-latest, macos-latest] steps: - uses: actions/checkout@v3 with: @@ -156,19 +133,32 @@ jobs: role-external-id: ${{ secrets.AWS_ROLE_EXTERNAL_ID }} role-duration-seconds: 900 - - name: Upload wheels to s3 +# pip install amazon.ion==${GITHUB_REF##*/v} || true + - name: Upload wheels to s3 and check release status run: | zip ion-python-wheels ./*.whl aws s3 mv ion-python-wheels.zip ${{ secrets.AWS_WHEELS_BUCKET_URL }} --acl bucket-owner-full-control + sleep 300s + for (( i=0; i<3; i++ )) do - id=$(1) - if [[ $id = 1 ]] + v="" + pip install -i https://test.pypi.org/simple/ amazon.ion==${GITHUB_REF##*/v} || true + v=$( pip show amazon.ion | grep Version ) + + if [[ $v == "Version: ${GITHUB_REF##*/v}" ]] then - echo "aaaaaaaaaaa" - exit 1 + echo "Found desired version: $v" + break fi - sleep 5s + sleep 300s done + + if [[ $v != "Version: ${GITHUB_REF##*/v}" ]] + then + echo "Exiting because unable to install the new version from PYPI" + exit 1 + fi + diff --git a/setup.py b/setup.py index 1ae878bc7..f7e75e911 100644 --- a/setup.py +++ b/setup.py @@ -50,7 +50,7 @@ def run_setup(): setup( name='amazon.ion', - version='0.9.72', + version='0.9.73', description='A Python implementation of Amazon Ion.', url='http://github.com/amzn/ion-python', author='Amazon Ion Team',