77 - develop
88 pull_request :
99 branches :
10- - " ** "
10+ - " *"
1111
1212concurrency :
1313 group : tests-${{ github.head_ref || github.ref }}
1919 runs-on : ${{ matrix.image }}
2020 strategy :
2121 matrix :
22- os : [ubuntu, windows, macos-x86_64, macos-arm64]
23- python-version : ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
22+ os : [ubuntu] # , windows, macos-x86_64, macos-arm64]
23+ python-version : ["3.8", "3.9", "3.10", "3.11"] # , "3.12", "3.13"]
2424 qt-version : ["pyside2", "pyside6", "pyqt5", "pyqt6"]
2525 include :
2626 - os : ubuntu
@@ -61,56 +61,17 @@ jobs:
6161 with :
6262 python-version : ${{ matrix.python-version }}
6363
64- - name : Get full Python version
65- id : full-python-version
66- run : echo version=$(python -c "import sys; print('-'.join(str(v) for v in sys.version_info))") >> $GITHUB_OUTPUT
67-
68- - name : Bootstrap poetry
69- run : |
70- curl -sSL https://install.python-poetry.org | POETRY_VERSION=1.8.4 python - -y
71-
72- - name : Update Path
73- if : ${{ matrix.os != 'windows' }}
74- run : echo "$HOME/.local/bin" >> $GITHUB_PATH
75-
76- - name : Update Path for Windows
77- if : ${{ matrix.os == 'windows' }}
78- run : echo "$APPDATA\Python\Scripts" >> $GITHUB_PATH
79-
80- - name : Enable long paths on Windows
81- if : ${{ matrix.os == 'windows' }}
82- run : git config --system core.longpaths true
83-
84- - name : Configure poetry
85- run : poetry config virtualenvs.in-project true
86-
87- - name : Setup cache
88- uses : actions/cache@v4
89- id : cache
64+ - name : Install uv
65+ uses : astral-sh/setup-uv@v6
9066 with :
91- path : .venv
92- key : venv-${{ runner.os }}-${{ matrix.qt-version }}-${{ steps.full-python-version.outputs.version }}-${{ hashFiles('**/poetry.lock') }}
93-
94- - name : Valdate cache
95- if : steps.cache.outputs.cache-hit == 'true'
96- run : |
97- # `timeout` is not available on macos, so we define a custom function.
98- [ "$(command -v timeout)" ] || function timeout() { perl -e 'alarm shift; exec @ARGV' "$@"; }
99-
100- # Using `timeout` is a safeguard against the Poetry command hanging for some reason.
101- timeout 10s poetry run pip --version || rm -rf .venv
102-
103- - name : Check lock file
104- run : poetry check --lock
105-
106- - name : Install dependencies
107- run : poetry install --with github-actions
67+ version : " 0.8.3"
68+ enable-cache : false
10869
109- # - name: Run mypy
110- # run: poetry run mypy
70+ - name : Install qasync
71+ run : uv sync --locked --dev
11172
112- - name : Install Qt
113- run : poetry run pip install --ignore-installed ${{ matrix.qt-version }}
73+ - name : Install Qt ${{ matrix.qt-version }}
74+ run : uv pip install ${{ matrix.qt-version }}
11475
11576 - name : Install libxcb dependencies
11677 if : ${{ matrix.os == 'ubuntu' }}
@@ -125,4 +86,21 @@ jobs:
12586 env :
12687 QT_API : ${{ matrix.qt-version }}
12788 with :
128- run : poetry run pytest --cov qasync -v
89+ run : uv run coverage run -m pytest --verbose tests/ && uv run coverage report -m
90+
91+ # combine-coverage:
92+ # needs: tests
93+ # name: combine and report coverage
94+ # runs-on: ubuntu-latest
95+ #
96+ # steps:
97+ # - uses: actions/checkout@v4
98+ # - run: pip install coverage
99+ #
100+ # - name: Download all coverage artifacts
101+ # uses: actions/download-artifact@v4
102+ # with:
103+ # path: coverage-artifacts
104+ #
105+ # - name: Comment with coverage report
106+ # uses: MishaKav/pytest-coverage-comment@v1
0 commit comments