--pre Test #2652
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
# An "early warning" cron job that will install dependencies | |
# with `pip install --pre` periodically to test for breakage | |
# (and open an issue if a test fails) | |
name: --pre Test | |
on: | |
schedule: | |
- cron: '0 */12 * * *' # every 12 hours | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
pull_request: | |
paths: | |
- '.github/workflows/test_prereleases.yml' | |
- 'resources/constraints/version_denylist.txt' | |
env: | |
COLUMNS: 120 | |
jobs: | |
test: | |
name: ${{ matrix.platform }} py${{ matrix.python }} ${{ matrix.backend }} --pre | |
timeout-minutes: 40 | |
runs-on: ${{ matrix.platform }} | |
permissions: | |
contents: read | |
issues: write | |
if: ${{ github.repository == 'napari/napari' || github.event_name == 'workflow_dispatch' }} | |
strategy: | |
fail-fast: false | |
matrix: | |
platform: [windows-latest, macos-latest, ubuntu-latest] | |
python: [3.12] | |
backend: [pyqt5, pyqt6] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python }} | |
cache-dependency-path: pyproject.toml | |
- uses: tlambert03/setup-qt-libs@v1 | |
- name: Setup Graphviz | |
uses: ts-graphviz/setup-graphviz@v2 | |
continue-on-error: true | |
- name: Set Windows resolution | |
if: runner.os == 'Windows' | |
run: Set-DisplayResolution -Width 1920 -Height 1080 -Force | |
shell: powershell | |
- name: Install Windows OpenGL | |
if: runner.os == 'Windows' | |
run: | | |
git clone --depth 1 https://github.com/pyvista/gl-ci-helpers.git | |
powershell gl-ci-helpers/appveyor/install_opengl.ps1 | |
if (Test-Path -Path "C:\Windows\system32\opengl32.dll" -PathType Leaf) {Exit 0} else {Exit 1} | |
shell: powershell | |
- name: Install dependencies | |
run: | | |
pip install --upgrade pip | |
pip install setuptools tox tox-gh-actions | |
- name: Test with tox | |
# run tests using pip install --pre | |
uses: aganders3/headless-gui@v2 | |
with: | |
run: python -m tox -v --pre | |
env: | |
PLATFORM: ${{ matrix.platform }} | |
BACKEND: ${{ matrix.backend }} | |
COVERAGE: "no_cov" | |
PYVISTA_OFF_SCREEN: True # required for opengl on windows | |
PIP_CONSTRAINT: resources/constraints/version_denylist.txt | |
# If something goes wrong, we can open an issue in the repo | |
- name: Report Failures | |
if: ${{ failure() && github.event_name == 'schedule' }} | |
uses: JasonEtco/create-an-issue@v2 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
PLATFORM: ${{ matrix.platform }} | |
PYTHON: ${{ matrix.python }} | |
BACKEND: ${{ matrix.backend }} | |
RUN_ID: ${{ github.run_id }} | |
TITLE: '[test-bot] pip install --pre is failing' | |
with: | |
filename: .github/TEST_FAIL_TEMPLATE.md | |
update_existing: true |