diff --git a/.github/workflows/test_development_versions.yml b/.github/workflows/test_development_versions.yml index 184c7fb..2cfe8c6 100644 --- a/.github/workflows/test_development_versions.yml +++ b/.github/workflows/test_development_versions.yml @@ -28,31 +28,39 @@ jobs: uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} - - name: Determine development versions - shell: bash - run: | - # NOTE: by determining the current git commit SHAs, we can ensure that - # the individually run tox environments indeed actually use the exact - # same versions (which may not be the case if at the exact time a new - # commit gets added to the respective repositories). - # Additionally, using these commit SHAs ensures that the locally built - # Python wheels get cached, ensuring a faster tox environment setup - # for the multiple jobs below. - QISKIT_SHA=$(git ls-remote "https://github.com/Qiskit/qiskit" | grep HEAD | awk '{print $1}') - echo "QISKIT_SHA=$QISKIT_SHA" >> "$GITHUB_ENV" - echo "Using Qiskit/qiskit @ $QISKIT_SHA" - QISKIT_IBM_RUNTIME_SHA=$(git ls-remote "https://github.com/Qiskit/qiskit-ibm-runtime" | grep HEAD | awk '{print $1}') - echo "QISKIT_IBM_RUNTIME_SHA=$QISKIT_IBM_RUNTIME_SHA" >> "$GITHUB_ENV" - echo "Using Qiskit/qiskit-ibm-runtime @ $QISKIT_IBM_RUNTIME_SHA" - - name: Pinning development versions - shell: bash + - name: Upgrade pip run: | python -m pip install --upgrade pip - python -m pip install tox extremal-python-dependencies==0.0.3 - extremal-python-dependencies pin-dependencies \ - "qiskit @ git+https://github.com/Qiskit/qiskit.git@$QISKIT_SHA" \ - "qiskit-ibm-runtime @ git+https://github.com/Qiskit/qiskit-ibm-runtime.git@$QISKIT_IBM_RUNTIME_SHA" \ - --inplace + - name: Install tools from pypi + run: | + python -m pip install tox build extremal-python-dependencies==0.0.3 + - name: Build Qiskit SDK development wheel + run: | + git clone https://github.com/Qiskit/qiskit + cd qiskit + git rev-parse HEAD + python -m build --wheel + - name: Build qiskit-ibm-runtime development wheel + run: | + git clone https://github.com/Qiskit/qiskit-ibm-runtime + cd qiskit-ibm-runtime + git rev-parse HEAD + python -m build --wheel + - name: Build qiskit-addon-utils development wheel + run: | + git clone https://github.com/Qiskit/qiskit-addon-utils + cd qiskit-addon-utils + git rev-parse HEAD + # Unpin qiskit<2 + extremal-python-dependencies pin-dependencies --inplace qiskit + python -m build --wheel + - name: Pin development versions + shell: bash + run: >- + extremal-python-dependencies pin-dependencies --inplace + "qiskit @ file:$(echo qiskit/dist/*.whl)" + "qiskit-ibm-runtime @ file:$(echo qiskit-ibm-runtime/dist/*.whl)" + "qiskit-addon-utils @ file:$(echo qiskit-addon-utils/dist/*.whl)" - name: Test using tox environment shell: bash run: |