fix empty circuit error #790
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Package and release | |
on: | |
pull_request: | |
push: | |
branches: [main] | |
release: | |
types: [published] | |
jobs: | |
package: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
# Necessary to get tags for correct versioning | |
fetch-depth: 0 | |
- uses: ./.github/actions/python-poetry-install | |
with: | |
poetry-version: '1.4.0' | |
python-version: '3.9' | |
- run: | | |
poetry self add "poetry-dynamic-versioning[plugin]" | |
- run: | | |
poetry env use 3.9 | |
mkdir -p dist | |
cp -f NOTICE quri_parts/ | |
poetry build | |
cd packages | |
for pkg in * | |
do | |
cd $pkg | |
cp -f NOTICE quri_parts/$pkg/ | |
poetry build | |
mv dist/* ../../dist | |
cd .. | |
done | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: QURI parts packages | |
path: dist/* | |
if-no-files-found: error | |
release: | |
needs: [package] | |
if: github.event_name == 'release' | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/download-artifact@v3 | |
with: | |
name: QURI parts packages | |
- name: Install Twine | |
run: python -m pip install twine | |
- name: Release to PyPI | |
run: python -m twine upload * | |
env: | |
TWINE_USERNAME: "__token__" | |
TWINE_PASSWORD: ${{ secrets.TWINE_API_TOKEN }} |