Initialize
Some checks failed
Build wheels / build (ubuntu-latest, 3.11) (push) Has been cancelled
Build wheels / build (ubuntu-latest, 3.12) (push) Has been cancelled
Build wheels / build (ubuntu-latest, 3.13) (push) Has been cancelled
docs / evaluate-label (push) Has been cancelled
Tests / check (push) Has been cancelled
docs / deploy-docs (push) Has been cancelled
Tests / build (ubuntu-latest, 3.11) (push) Has been cancelled
Tests / build (ubuntu-latest, 3.12) (push) Has been cancelled
Tests / build (ubuntu-latest, 3.13) (push) Has been cancelled

This commit is contained in:
2026-04-15 21:10:21 +08:00
commit c4a82614b3
47 changed files with 9702 additions and 0 deletions

22
.github/workflows/deploy.yml vendored Normal file
View File

@@ -0,0 +1,22 @@
# A single CI script with github workflow
name: Build wheels
on:
push:
release:
types:
- published
jobs:
build:
strategy:
matrix:
os: [ubuntu-latest]
python-version: ["3.11", "3.12", "3.13"]
uses: qiboteam/workflows/.github/workflows/deploy-pip-poetry.yml@v1
with:
os: ${{ matrix.os }}
python-version: ${{ matrix.python-version }}
publish: ${{ github.event_name == 'release' && github.event.action == 'published' && matrix.os == 'ubuntu-latest' && matrix.python-version == '3.9' }}
poetry-extras: "--with docs,tests,analysis"
secrets: inherit

38
.github/workflows/publish.yml vendored Normal file
View File

@@ -0,0 +1,38 @@
name: docs
on:
workflow_dispatch:
push:
branches: [main]
tags:
- "*"
jobs:
evaluate-label:
runs-on: ubuntu-latest
outputs:
label: ${{ steps.label_step.outputs.version}}
steps:
- name: checks for the label
id: label_step
run: |
if [[ "${{ github.ref }}" == "refs/heads/main" ]]; then
echo "version=latest" >> $GITHUB_OUTPUT
fi
if [[ "${{ github.ref_type }}" == "branch" ]] && [[ "${{ github.ref }}" != "refs/heads/main" ]]; then
exit 1
fi
if [[ "${{ github.ref_type }}" == "tag" ]]; then
echo "version=stable" >> $GITHUB_OUTPUT
fi
deploy-docs:
needs: [evaluate-label]
uses: qiboteam/workflows/.github/workflows/deploy-ghpages-latest-stable.yml@v1
with:
python-version: "3.11"
package-manager: "poetry"
dependency-path: "**/poetry.lock"
trigger-label: "${{needs.evaluate-label.outputs.label}}"
project: qibotn
poetry-extras: --with docs

38
.github/workflows/rules.yml vendored Normal file
View File

@@ -0,0 +1,38 @@
# A single CI script with github workflow
name: Tests
env:
CUDA_PATH:
on:
workflow_dispatch:
push:
pull_request:
types: [labeled]
jobs:
check:
# job to check cuda availability for local gpu host runners
runs-on: ubuntu-latest
steps:
- id: step1
run: echo "test=${{ env.CUDA_PATH != ''}}" >> "$GITHUB_OUTPUT"
- id: step2
run: echo "test=${{ contains(github.event.pull_request.labels.*.name, 'run-workflow') || github.event_name == 'push' }}" >> "$GITHUB_OUTPUT"
outputs:
cuda_avail: ${{ fromJSON(steps.step1.outputs.test) && fromJSON(steps.step2.outputs.test) }}
build:
# job to build
needs: check
if: ${{fromJSON(needs.check.outputs.cuda_avail)}}
strategy:
matrix:
os: [ubuntu-latest]
python-version: ["3.11", "3.12", "3.13"]
uses: qiboteam/workflows/.github/workflows/rules-poetry.yml@v1
with:
os: ${{ matrix.os }}
python-version: ${{ matrix.python-version }}
poetry-extras: "--with analysis,tests"
secrets: inherit