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

chore: Fix jupyter failing test by using constraints #1093

Merged
merged 6 commits into from
Apr 12, 2024
Merged
Show file tree
Hide file tree
Changes from 4 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
6 changes: 3 additions & 3 deletions .azure-pipelines/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ parameters:
type: string

steps:
- {task: UsePythonVersion@0, inputs: {versionSpec: '3.9'}}
- {task: UsePythonVersion@0, inputs: {versionSpec: '3.11'}}
- template: pip_cache.yaml
parameters:
key: test | requirements/constraints_py3.9.txt | "$(Agent.OS)" | "$(PY)"
key: test | requirements/constraints_py3.11.txt | "$(Agent.OS)" | "$(PY)"
path: ${{ parameters.cache_dir }}
- task: DownloadPipelineArtifact@2
inputs:
Expand All @@ -16,7 +16,7 @@ steps:
pip install -U pip wheel setuptools virtualenv
pip install -r requirements/requirements_dev.txt
displayName: "Install deps"
- script: tox -e py39-PyQt5-azure
- script: tox -e py311-PyQt5-azure
displayName: "Run Tox"
env:
CODECOV_TOKEN: $(codecov_token_secret)
Expand Down
8 changes: 5 additions & 3 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -97,16 +97,18 @@ stages:
DATA_PATH: typy_neuronow2
pip_cache_dir: $(Pipeline.Workspace)/.pip
steps:
- {task: UsePythonVersion@0, inputs: {versionSpec: '3.9', architecture: x64}}
- {task: UsePythonVersion@0, inputs: {versionSpec: '3.11', architecture: x64}}
- template: .azure-pipelines/pip_cache.yaml
parameters:
key: notebook | requirements/constraints_py3.9.txt | "$(PY)"
key: notebook | requirements/constraints_py3.11.txt | "$(PY)"
path: $(pip_cache_dir)
- bash: |
python -m pip install tox
displayName: Test notebook
displayName: "Install tox"
- bash: tox -e jupyter
displayName: "Run Notebook"
env:
PIP_CONSTRAINT: requirements/constraints_py3.11.txt

- stage: Tests_linux
dependsOn: [GetTestData, formatting_check]
Expand Down
8 changes: 4 additions & 4 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ conda_env=environment.yml
deps=
pytest
pytest-json-report
lxml_html_clean

[testenv:py{38,39,310,311}-{PyQt5,PySide2,PyQt6,PySide6}-napari_{417,418,419,repo}]
deps =
Expand Down Expand Up @@ -98,10 +99,11 @@ setenv =
deps =
{[base]deps}
setuptools_scm[toml]>=3.4
lxml_html_clean
commands =
coverage run -m pytest --json-report --json-report-file={toxinidir}/report-{envname}-{sys_platform}.json

[testenv:py{38,39,310}-{PyQt5, PySide2,PyQt6,PySide6}-azure]
[testenv:py{38,39,310,311}-{PyQt5, PySide2,PyQt6,PySide6}-azure]
deps =
pytest-azurepipelines
{[testenv]deps}
Expand All @@ -110,10 +112,8 @@ deps =
[testenv:jupyter]
deps =
{[testenv]deps}
jupyter[all]
jupyter[all]
jupyter
matplotlib
-crequirements/constraints_py3.9.txt
setenv =
DATA_PATH = {toxinidir}/typy_neuronow2
commands =
Expand Down