diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index 849c6cf..8c40ede 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -28,31 +28,34 @@ jobs: url: ${{ steps.deployment.outputs.page_url }} runs-on: ubuntu-latest steps: - - name: Checkout code - uses: actions/checkout@v4 - - name: Install Poetry - uses: abatilo/actions-poetry@v2 - with: - poetry-version: '1.7.1' + - uses: actions/checkout@v4 - name: Install Python uses: actions/setup-python@v5 with: - python-version: '3.11' - cache: "poetry" - - name: Check Poetry lock file consistency - run: poetry check --lock + python-version: 3.12 + cache: "pip" + - name: Install uv + run: | + # https://github.com/astral-sh/uv/issues/1386#issuecomment-1947801083 + echo "VIRTUAL_ENV=${Python_ROOT_DIR}" >> $GITHUB_ENV + pip install uv - name: Install dependencies - run: poetry install --sync + run: | + # FIXME: https://github.com/Qiskit/qiskit_sphinx_theme/issues/567 + echo 'furo==2023.9.10' > furo-override.txt + uv pip compile pyproject.toml --all-extras --override furo-override.txt > requirements.txt + uv pip sync --strict requirements.txt + uv pip install --editable . - name: Check version numbers consistency - run: poetry run poe version_check + run: poe version_check - name: Build documentation - run: poetry run poe docs - - name: Setup Pages - uses: actions/configure-pages@v4 - - name: Upload artifact - uses: actions/upload-pages-artifact@v3 - with: - path: 'docs/_build' - - name: Deploy to GitHub Pages - id: deployment - uses: actions/deploy-pages@v4 + run: poe docs + # - name: Setup Pages + # uses: actions/configure-pages@v4 + # - name: Upload artifact + # uses: actions/upload-pages-artifact@v3 + # with: + # path: 'docs/_build' + # - name: Deploy to GitHub Pages + # id: deployment + # uses: actions/deploy-pages@v4 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index db4370a..fa5f3eb 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -3,41 +3,44 @@ on: push: tags: - 'v*' + # Run on manual triggers + workflow_dispatch: jobs: - wheel-build: + release: name: Build and Publish Release Artifacts runs-on: ubuntu-latest - environment: release - permissions: - id-token: write - contents: write + # environment: release + # permissions: + # id-token: write + # contents: write steps: - name: Checkout code uses: actions/checkout@v4 - name: Install Python uses: actions/setup-python@v5 with: - python-version: '3.11' - - name: Install Poetry - uses: abatilo/actions-poetry@v2 - with: - poetry-version: '1.7.1' + python-version: 3.12 + - name: Install uv + run: | + # https://github.com/astral-sh/uv/issues/1386#issuecomment-1947801083 + echo "VIRTUAL_ENV=${Python_ROOT_DIR}" >> $GITHUB_ENV + pip install uv - name: Install release dependencies - run: pip install -U typer mistletoe + run: | + uv pip install typer mistletoe hatch - name: Build packages run: | - poetry build - shell: bash + hatch build - name: Upload artifacts uses: actions/upload-artifact@v4 with: path: ./dist/qiskit* - name: Extract changelog run: python scripts/extract-changelog.py ${{ github.ref_name }} | tee ${{ github.workspace }}-CHANGELOG.txt - - name: Create Github release - uses: softprops/action-gh-release@v1 - with: - files: ./dist/qiskit* - body_path: ${{ github.workspace }}-CHANGELOG.txt - - name: Publish to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 + # - name: Create Github release + # uses: softprops/action-gh-release@v1 + # with: + # files: ./dist/qiskit* + # body_path: ${{ github.workspace }}-CHANGELOG.txt + # - name: Publish to PyPI + # uses: pypa/gh-action-pypi-publish@release/v1 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 926548e..8cef291 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -97,7 +97,8 @@ jobs: - name: Lock dependencies run: | echo "qiskit==${{ matrix.qiskit-version }}" > qiskit-override.txt - echo 'furo==2023.9.10' > furo-override.txt # https://github.com/Qiskit/qiskit_sphinx_theme/issues/567 + # FIXME: https://github.com/Qiskit/qiskit_sphinx_theme/issues/567 + echo 'furo==2023.9.10' > furo-override.txt uv pip compile pyproject.toml --all-extras --override qiskit-override.txt --override furo-override.txt > requirements.txt - name: Install project run: |