feat: add QIcon backed by iconify #809
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: Test | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
on: | |
push: | |
branches: | |
- main | |
tags: | |
- "v*" # Push events to matching v*, i.e. v1.0, v20.15.10 | |
pull_request: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
test: | |
name: ${{ matrix.platform }} py${{ matrix.python-version }} ${{ matrix.backend }} | |
runs-on: ${{ matrix.platform }} | |
strategy: | |
fail-fast: false | |
matrix: | |
platform: [ubuntu-latest, windows-latest, macos-latest] | |
python-version: ["3.8", "3.9", "3.10", "3.11"] | |
backend: [pyqt5, pyside2, pyqt6] | |
exclude: | |
# Abort (core dumped) on linux pyqt6, unknown reason | |
- platform: ubuntu-latest | |
backend: pyqt6 | |
# lack of wheels for pyside2/py3.11 | |
- python-version: "3.11" | |
backend: pyside2 | |
include: | |
- python-version: "3.10" | |
platform: macos-latest | |
backend: pyside6 | |
- python-version: "3.11" | |
platform: macos-latest | |
backend: pyside6 | |
- python-version: "3.10" | |
platform: windows-latest | |
backend: pyside6 | |
- python-version: "3.11" | |
platform: windows-latest | |
backend: pyside6 | |
- python-version: "3.12" | |
platform: macos-latest | |
backend: pyqt6 | |
# legacy Qt | |
- python-version: 3.8 | |
platform: ubuntu-latest | |
backend: "pyqt5==5.12.*" | |
- python-version: 3.8 | |
platform: ubuntu-latest | |
backend: "pyqt5==5.13.*" | |
- python-version: 3.8 | |
platform: ubuntu-latest | |
backend: "pyqt5==5.14.*" | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- uses: tlambert03/[email protected] | |
- name: Linux opengl | |
if: runner.os == 'Linux' && ( startsWith(matrix.backend, 'pyside6') || startsWith(matrix.backend, 'pyqt6') ) | |
run: sudo apt-get install -y libopengl0 libegl1-mesa libxcb-xinput0 | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install -e .[test] | |
python -m pip install ${{ matrix.backend }} | |
- name: Test | |
uses: aganders3/[email protected] | |
with: | |
run: python -m pytest --color=yes --cov=superqt --cov-report=xml | |
- name: Coverage | |
uses: codecov/codecov-action@v3 | |
test_old_qtpy: | |
name: qtpy minreq | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: tlambert03/[email protected] | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.8" | |
- name: install | |
run: | | |
python -m pip install -U pip | |
python -m pip install -e .[test,pyqt5] | |
python -m pip install qtpy==1.1.0 typing-extensions==3.7.4.3 | |
- name: Test | |
uses: aganders3/[email protected] | |
with: | |
run: python -m pytest --color=yes | |
test_napari: | |
name: napari tests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
path: superqt | |
- uses: actions/checkout@v4 | |
with: | |
repository: napari/napari | |
path: napari-repo | |
fetch-depth: 2 | |
- uses: tlambert03/setup-qt-libs@v1 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.10" | |
- name: install | |
run: | | |
python -m pip install -U pip | |
python -m pip install ./superqt | |
python -m pip install ./napari-repo[testing,pyqt5] | |
- name: Test napari | |
uses: aganders3/[email protected] | |
with: | |
working-directory: napari-repo | |
run: python -m pytest --color=yes napari/_qt | |
check-manifest: | |
name: Check Manifest | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.x" | |
- run: pip install check-manifest && check-manifest | |
deploy: | |
# this will run when you have tagged a commit, starting with "v*" | |
# and requires that you have put your twine API key in your | |
# github secrets (see readme for details) | |
needs: [test, check-manifest] | |
if: ${{ github.repository == 'pyapp-kit/superqt' && contains(github.ref, 'tags') }} | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: "3.x" | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install build twine | |
- name: Build and publish | |
env: | |
TWINE_USERNAME: __token__ | |
TWINE_PASSWORD: ${{ secrets.TWINE_API_KEY }} | |
run: | | |
git tag | |
python -m build | |
twine check dist/* | |
twine upload dist/* | |
- uses: softprops/action-gh-release@v1 | |
with: | |
generate_release_notes: true |