Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changed to install qiskit not qiskit-terra #58

Merged
merged 1 commit into from
Feb 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 17 additions & 17 deletions .github/actions/install-main-dependencies/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ inputs:
python-version:
description: 'Python version'
required: true
terra-main:
description: 'Use Terra main'
qiskit-main:
description: 'Use Qiskit main'
required: true
nature-main:
description: 'Use Nature main'
Expand All @@ -30,17 +30,17 @@ runs:
steps:
- name: Get main last commit ids
run: |
echo "TERRA_HASH=$(git ls-remote --heads https://github.com/Qiskit/qiskit-terra.git refs/heads/main | awk '{print $1}')" >> $GITHUB_ENV
echo "QISKIT_HASH=$(git ls-remote --heads https://github.com/Qiskit/qiskit.git refs/heads/main | awk '{print $1}')" >> $GITHUB_ENV
echo "NATURE_HASH=$(git ls-remote --heads https://github.com/Qiskit/qiskit-nature.git refs/heads/main | awk '{print $1}')" >> $GITHUB_ENV
shell: bash
- name: Terra Cache
- name: Qiskit Cache
env:
CACHE_VERSION: v1
id: terra-cache
id: qiskit-cache
uses: actions/cache@v3
with:
path: terra-cache
key: terra-cache-${{ inputs.os }}-${{ inputs.python-version }}-${{ env.TERRA_HASH }}-${{ env.CACHE_VERSION }}
path: qiskit-cache
key: qiskit-cache-${{ inputs.os }}-${{ inputs.python-version }}-${{ env.QISKIT_HASH }}-${{ env.CACHE_VERSION }}
- name: Nature Cache
env:
CACHE_VERSION: v1
Expand All @@ -49,15 +49,15 @@ runs:
with:
path: nature-cache
key: nature-cache-${{ inputs.os }}-${{ inputs.python-version }}-${{ env.NATURE_HASH }}-${{ env.CACHE_VERSION }}
- name: Install Terra
- name: Install Qiskit
env:
MACOSX_DEPLOYMENT_TARGET: 10.15
run: |
if [ "${{ inputs.terra-main }}" == "true" ]; then
echo 'Install Terra from Main'
BASE_DIR=terra-cache
if [ "${{ inputs.qiskit-main }}" == "true" ]; then
echo 'Install Qiskit from Main'
BASE_DIR=qiskit-cache
build_from_main=true
cache_hit=${{ steps.terra-cache.outputs.cache-hit }}
cache_hit=${{ steps.qiskit-cache.outputs.cache-hit }}
echo "cache hit: ${cache_hit}"
if [ "$cache_hit" == "true" ]; then
pip_result=0
Expand All @@ -73,19 +73,19 @@ runs:
if [ "$build_from_main" == "true" ]; then
echo 'Create wheel file from main'
pip install -U wheel setuptools_rust
git clone --depth 1 --branch main https://github.com/Qiskit/qiskit-terra.git /tmp/qiskit-terra
pushd /tmp/qiskit-terra
git clone --depth 1 --branch main https://github.com/Qiskit/qiskit.git /tmp/qiskit
pushd /tmp/qiskit
python setup.py bdist_wheel
popd
cp -rf /tmp/qiskit-terra/dist/*.whl "${BASE_DIR}"
cp -rf /tmp/qiskit/dist/*.whl "${BASE_DIR}"
pushd "${BASE_DIR}"
python -m pip install *.whl
popd
pip uninstall -y setuptools_rust
fi
else
echo 'Install Terra from Stable'
pip install -U qiskit-terra
echo 'Install Qiskit from Stable'
pip install -U qiskit
fi
shell: bash
- name: Install Nature from Main
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This code is part of a Qiskit project.
#
# (C) Copyright IBM 2022, 2023.
# (C) Copyright IBM 2022, 2024.
#
# This code is licensed under the Apache License, Version 2.0. You may
# obtain a copy of this license in the LICENSE.txt file in the root directory
Expand Down Expand Up @@ -44,7 +44,7 @@ jobs:
if: ${{ !startsWith(github.ref, 'refs/heads/stable') && !startsWith(github.base_ref, 'stable/') }}
- name: Install Dependencies
run: |
pip install jupyter qiskit-terra[visualization]
pip install jupyter qiskit[visualization]
sudo apt-get install -y pandoc graphviz
shell: bash
- uses: ./.github/actions/install-nature-pyscf
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ jobs:
os: ${{ matrix.os }}
- name: Install Dependencies
run: |
pip install jupyter qiskit-terra[visualization]
pip install jupyter qiskit[visualization]
sudo apt-get -y install pandoc graphviz
sudo apt-get -y install python3-enchant
sudo apt-get -y install hunspell-en-us
Expand Down Expand Up @@ -134,7 +134,7 @@ jobs:
with:
os: ${{ matrix.os }}
python-version: ${{ matrix.python-version }}
terra-main: "false"
qiskit-main: "false"
nature-main: "false"
if: ${{ !startsWith(github.ref, 'refs/heads/stable') && !startsWith(github.base_ref, 'stable/') }}
- uses: ./.github/actions/install-nature-pyscf
Expand Down
Loading