Skip to content

Commit

Permalink
Merge remote-tracking branch 'ibm/main' into has-pygments
Browse files Browse the repository at this point in the history
  • Loading branch information
jakelishman committed Jul 6, 2023
2 parents 56921c2 + 163875e commit d2caa14
Show file tree
Hide file tree
Showing 793 changed files with 31,414 additions and 8,985 deletions.
2 changes: 1 addition & 1 deletion .azure/docs-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
- bash: |
set -e
python -m pip install --upgrade pip setuptools wheel
pip install -U "tox<4.4.0"
python -m pip install -U "tox<4.4.0"
sudo apt-get update
sudo apt-get install -y graphviz
displayName: 'Install dependencies'
Expand Down
6 changes: 4 additions & 2 deletions .azure/lint-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ jobs:
python -m pip install --upgrade pip setuptools wheel virtualenv
virtualenv test-job
source test-job/bin/activate
pip install -U pip setuptools wheel
pip install -U \
python -m pip install -U pip setuptools wheel
python -m pip install -U \
-c constraints.txt \
-r requirements.txt \
-r requirements-dev.txt \
Expand All @@ -43,6 +43,8 @@ jobs:
- bash: |
set -e
source test-job/bin/activate
echo "Running ruff"
ruff qiskit test tools examples setup.py
echo "Running pylint"
pylint -rn qiskit test tools
echo "Running Cargo Clippy"
Expand Down
14 changes: 7 additions & 7 deletions .azure/test-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,11 @@ jobs:
# Use stable Rust, rather than MSRV, to spot-check that stable builds properly.
rustup override set stable
source test-job/bin/activate
pip install -U pip setuptools wheel
python -m pip install -U pip setuptools wheel
# Install setuptools-rust for building sdist
pip install -U -c constraints.txt setuptools-rust
python -m pip install -U -c constraints.txt setuptools-rust
python setup.py sdist
pip install -U \
python -m pip install -U \
-c constraints.txt \
-r requirements.txt \
-r requirements-dev.txt \
Expand All @@ -75,7 +75,7 @@ jobs:
- bash: |
set -e
source test-job/bin/activate
pip install -U \
python -m pip install -U \
-c constraints.txt \
-r requirements.txt \
-r requirements-dev.txt \
Expand All @@ -87,7 +87,7 @@ jobs:
- bash: |
set -e
source test-job/bin/activate
pip install -U \
python -m pip install -U \
-c constraints.txt \
"cplex ; python_version < '3.11'" \
"qiskit-aer" \
Expand Down Expand Up @@ -119,7 +119,7 @@ jobs:
set -e
source test-job/bin/activate
cp tools/subunit_to_junit.py /tmp/terra-tests/.
pip install -U junitxml
python -m pip install -U junitxml
pushd /tmp/terra-tests
mkdir -p junit
stestr last --subunit | ./subunit_to_junit.py -o junit/test-results.xml
Expand Down Expand Up @@ -174,7 +174,7 @@ jobs:
- bash: |
set -e
virtualenv image_tests
image_tests/bin/pip install -U \
image_tests/bin/python -m pip install -U \
-c constraints.txt \
-r requirements.txt \
-e ".[visualization]"
Expand Down
6 changes: 3 additions & 3 deletions .azure/test-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ jobs:
python -m pip install --upgrade pip setuptools wheel virtualenv
virtualenv test-job
source test-job/bin/activate
pip install -U pip setuptools wheel
pip install -U \
python -m pip install -U pip setuptools wheel
python -m pip install -U \
-c constraints.txt \
-r requirements.txt \
-r requirements-dev.txt \
Expand All @@ -59,7 +59,7 @@ jobs:
- bash: |
set -e
source test-job/bin/activate
pip install -U junitxml
python -m pip install -U junitxml
mkdir -p junit
stestr last --subunit | tools/subunit_to_junit.py -o junit/test-results.xml
pushd .stestr
Expand Down
6 changes: 3 additions & 3 deletions .azure/test-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ jobs:
python -m pip install --upgrade pip setuptools wheel virtualenv
virtualenv test-job
source test-job/Scripts/activate
pip install -U pip setuptools wheel
pip install -U \
python -m pip install -U pip setuptools wheel
python -m pip install -U \
-c constraints.txt \
-r requirements.txt \
-r requirements-dev.txt \
Expand Down Expand Up @@ -63,7 +63,7 @@ jobs:
set -e
chcp.com 65001
source test-job/Scripts/activate
pip install -U junitxml
python -m pip install -U junitxml
mkdir -p junit
stestr last --subunit | python tools/subunit_to_junit.py -o junit/test-results.xml
pushd .stestr
Expand Down
2 changes: 1 addition & 1 deletion .azure/tutorials-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
set -e
git clone https://github.com/Qiskit/qiskit-tutorials --depth=1
python -m pip install --upgrade pip setuptools wheel
pip install -U \
python -m pip install -U \
-c constraints.txt \
-r requirements.txt \
-r requirements-dev.txt \
Expand Down
4 changes: 2 additions & 2 deletions .azure/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ jobs:
- bash: |
set -e
python -m pip install --upgrade pip
pip install cibuildwheel==2.11.2
pip install -U twine
python -m pip install cibuildwheel==2.13.0
python -m pip install -U twine
cibuildwheel --output-dir wheelhouse .
- task: PublishBuildArtifacts@1
Expand Down
16 changes: 9 additions & 7 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,13 @@ concurrency:
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
jobs:
coverage:
if: github.repository_owner == 'Qiskit'
name: Coverage
runs-on: ubuntu-latest
env:
# Override the `rust-toolchain.toml` file because `grcov` has greater requirements.
RUSTUP_TOOLCHAIN: stable

steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
Expand All @@ -20,11 +25,8 @@ jobs:
python-version: '3.8'

- name: Install Rust toolchain
uses: actions-rs/toolchain@v1
uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
override: true
profile: default
components: llvm-tools-preview

- name: Install dependencies
Expand All @@ -37,10 +39,10 @@ jobs:
# Modern pip (23.1+) can error out if it doesn't have `wheel` and we ask for one
# of these legacy packages.
- name: Ensure basic build requirements
run: pip install --upgrade pip setuptools wheel
run: python -m pip install -c constraints.txt --upgrade pip setuptools wheel

- name: Build and install qiskit-terra
run: pip install -e .
run: python -m pip install -c constraints.txt -e .
env:
CARGO_INCREMENTAL: 0
RUSTFLAGS: "-Cinstrument-coverage"
Expand All @@ -50,7 +52,7 @@ jobs:
- name: Generate unittest coverage report
run: |
set -e
pip install -r requirements-dev.txt qiskit-aer
python -m pip install -c constraints.txt -r requirements-dev.txt qiskit-aer
stestr run
# We set the --source-dir to '.' because we want all paths to appear relative to the repo
# root (we need to combine them with the Python ones), but we only care about `grcov`
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/neko.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,11 @@ concurrency:
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
jobs:
neko:
if: github.repository_owner == 'Qiskit'
name: Qiskit Neko Integration Tests
runs-on: ubuntu-latest
steps:
- uses: Qiskit/qiskit-neko@main
with:
test_selection: terra
repo_install_command: "pip install -c constraints.txt ."
13 changes: 7 additions & 6 deletions .github/workflows/randomized_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
workflow_dispatch:
jobs:
randomized_tests:
if: github.repository_owner == 'Qiskit'
name: Randomized tests
runs-on: ubuntu-latest
steps:
Expand All @@ -15,12 +16,12 @@ jobs:
python-version: '3.8'
- name: Install dependencies
run: |
pip install -U pip setuptools wheel
pip install -U -r requirements.txt -c constraints.txt
pip install -U -r requirements-dev.txt coveralls -c constraints.txt
pip install -c constraints.txt -e .
pip install "qiskit-ibmq-provider" -c constraints.txt
pip install "qiskit-aer"
python -m pip install -U pip setuptools wheel
python -m pip install -U -r requirements.txt -c constraints.txt
python -m pip install -U -r requirements-dev.txt coveralls -c constraints.txt
python -m pip install -c constraints.txt -e .
python -m pip install "qiskit-ibmq-provider" -c constraints.txt
python -m pip install "qiskit-aer"
env:
SETUPTOOLS_ENABLE_FEATURES: "legacy-editable"
- name: Run randomized tests
Expand Down
11 changes: 6 additions & 5 deletions .github/workflows/slow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
workflow_dispatch:
jobs:
slow-tests:
if: github.repository_owner == 'Qiskit'
name: Full-test-run-with-slow
runs-on: ubuntu-latest
steps:
Expand All @@ -15,11 +16,11 @@ jobs:
python-version: '3.10'
- name: Install dependencies
run: |
pip install -U pip setuptools wheel
pip install -U -r requirements.txt -c constraints.txt
pip install -U -r requirements-dev.txt -c constraints.txt
pip install -c constraints.txt -e .
pip install "qiskit-aer" "z3-solver" "cplex" -c constraints.txt
python -m pip install -U pip setuptools wheel
python -m pip install -U -r requirements.txt -c constraints.txt
python -m pip install -U -r requirements-dev.txt -c constraints.txt
python -m pip install -c constraints.txt -e .
python -m pip install "qiskit-aer" "z3-solver" "cplex" -c constraints.txt
env:
SETUPTOOLS_ENABLE_FEATURES: "legacy-editable"
- name: Run all tests including slow
Expand Down
24 changes: 9 additions & 15 deletions .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,14 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
python-version: '3.10'
- uses: dtolnay/rust-toolchain@stable
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
with:
platforms: all
- name: Build wheels
uses: pypa/cibuildwheel@v2.11.2
uses: pypa/cibuildwheel@v2.13.0
env:
CIBW_ARCHS_LINUX: s390x
CIBW_TEST_SKIP: "cp*"
Expand All @@ -52,16 +50,14 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
python-version: '3.10'
- uses: dtolnay/rust-toolchain@stable
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
with:
platforms: all
- name: Build wheels
uses: pypa/cibuildwheel@v2.11.2
uses: pypa/cibuildwheel@v2.13.0
env:
CIBW_ARCHS_LINUX: ppc64le
CIBW_TEST_SKIP: "cp*"
Expand All @@ -87,16 +83,14 @@ jobs:
- uses: actions/setup-python@v4
name: Install Python
with:
python-version: '3.7'
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
python-version: '3.10'
- uses: dtolnay/rust-toolchain@stable
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
with:
platforms: all
- name: Build wheels
uses: pypa/cibuildwheel@v2.11.2
uses: pypa/cibuildwheel@v2.13.0
env:
CIBW_ARCHS_LINUX: aarch64
- uses: actions/upload-artifact@v3
Expand Down
2 changes: 1 addition & 1 deletion .mergify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ pull_request_rules:
actions:
backport:
branches:
- stable/0.23
- stable/0.24
6 changes: 6 additions & 0 deletions CITATION.bib
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
@misc{Qiskit,
author = {{Qiskit contributors}},
title = {Qiskit: An Open-source Framework for Quantum Computing},
year = {2023},
doi = {10.5281/zenodo.2573505}
}
Loading

0 comments on commit d2caa14

Please sign in to comment.