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

Cleanup builds #91

Merged
merged 3 commits into from
Aug 11, 2021
Merged
Show file tree
Hide file tree
Changes from all 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
38 changes: 11 additions & 27 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,33 +10,17 @@ jobs:
fail-fast: false
matrix:
include:

- {os: windows-latest, python_Version: '3.6', toxenv: 'py36-PyQt5'}
- {os: windows-latest, python_Version: '3.6', toxenv: 'py36-PySide2'}
- {os: windows-latest, python_Version: '3.7', toxenv: 'py37-PyQt5'}
- {os: windows-latest, python_Version: '3.7', toxenv: 'py37-PySide2'}
- {os: windows-latest, python_Version: '3.8', toxenv: 'py38-PyQt5'}
- {os: windows-latest, python_Version: '3.8', toxenv: 'py38-PySide2'}
- {os: windows-latest, python_Version: '3.9', toxenv: 'py39-PyQt5'}
- {os: windows-latest, python_Version: '3.9', toxenv: 'py39-PySide2'}

# No Python 3.6
# Linux all failing on GHA
# {os: linux-latest, python_Version: '3.7', toxenv: 'py37-PyQt5'}
# {os: linux-latest, python_Version: '3.7', toxenv: 'py37-PySide2'}
# {os: linux-latest, python_Version: '3.8', toxenv: 'py38-PyQt5'}
# {os: linux-latest, python_Version: '3.8', toxenv: 'py38-PySide2'}
# {os: linux-latest, python_Version: '3.9', toxenv: 'py39-PyQt5'}
# {os: linux-latest, python_Version: '3.9', toxenv: 'py39-PySide2'}

# No Python 3.6
- {os: macos-latest, python_Version: '3.7', toxenv: 'py37-PyQt5'}
- {os: macos-latest, python_Version: '3.7', toxenv: 'py37-PySide2'}
- {os: macos-latest, python_Version: '3.8', toxenv: 'py38-PyQt5'}
- {os: macos-latest, python_Version: '3.8', toxenv: 'py38-PySide2'}
- {os: windows-latest, python_Version: '3.7', toxenv: 'py37'}
- {os: windows-latest, python_Version: '3.8', toxenv: 'py38'}
- {os: windows-latest, python_Version: '3.9', toxenv: 'py39'}
# Linux still not working
# {os: linux-latest, python_Version: '3.7', toxenv: 'py37'}
# {os: linux-latest, python_Version: '3.8', toxenv: 'py38'}
# {os: linux-latest, python_Version: '3.9', toxenv: 'py39'}
- {os: macos-latest, python_Version: '3.7', toxenv: 'py37'}
- {os: macos-latest, python_Version: '3.8', toxenv: 'py38'}
# missing numcodecs wheels on 3.9. conda not yet an option. see gh-51
# {os: macos-latest, python_Version: '3.9', toxenv: 'py39-PyQt5'}
# {os: macos-latest, python_Version: '3.9', toxenv: 'py39-PySide2'}
# {os: macos-latest, python_Version: '3.9', toxenv: 'py39'}

steps:
- uses: actions/checkout@v1
Expand Down Expand Up @@ -77,7 +61,7 @@ jobs:
python -m pip install -r requirements/requirements-dev.txt

- name: Test
run: tox -e 'py37-PyQt5-coverage'
run: tox -e 'py37-coverage'

- uses: codecov/codecov-action@v1
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pre.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ jobs:
fail-fast: false
matrix:
include:
- {os: windows-latest, python_Version: '3.9', toxenv: 'py39-PySide2'}
- {os: macos-latest, python_Version: '3.8', toxenv: 'py38-PyQt5'}
- {os: windows-latest, python_Version: '3.9', toxenv: 'py39'}
- {os: macos-latest, python_Version: '3.8', toxenv: 'py38'}

steps:
- uses: actions/checkout@v1
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/zarr-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,10 @@ jobs:
- name: Install dependencies
shell: bash -l {0}
run: |
python -m pip install --upgrade pip wheel pytest tox .[napari]
python -m pip install --upgrade pip wheel pytest tox
python -m pip install \
git+https://github.com/zarr-developers/zarr-python.git@master

- name: Run pytest
shell: bash -l {0}
run: pytest --ignore=tests/test_napari.py # segfaults
run: pytest
2 changes: 1 addition & 1 deletion .isort.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[settings]
known_third_party = cv2,dask,numpy,pytest,scipy,setuptools,skimage,vispy,zarr
known_third_party = cv2,dask,numpy,pytest,scipy,setuptools,skimage,zarr
multi_line_output=6
include_trailing_comma=False
force_grid_wrap=0
Expand Down
3 changes: 1 addition & 2 deletions ome_zarr/reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import dask.array as da
import numpy as np
from dask import delayed
from vispy.color import Colormap

from .io import ZarrLocation
from .types import JSONDict
Expand Down Expand Up @@ -337,7 +336,7 @@ def __init__(self, node: Node) -> None:
# TODO: make this value an enumeration
if model == "greyscale":
rgb = [1, 1, 1]
colormaps.append(Colormap([[0, 0, 0], rgb]))
colormaps.append([[0, 0, 0], rgb])

label = ch.get("label", None)
if label is not None:
Expand Down
1 change: 0 additions & 1 deletion requirements/requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
black
napari
cython >= 0.29.16
numpy >= 1.16.0
pre-commit
Expand Down
1 change: 0 additions & 1 deletion requirements/requirements-test.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
pytest
pytest-cov
pytest-qt
codecov
1 change: 0 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ def read(fname):
install_requires += (["requests"],)
install_requires += (["scikit-image"],)
install_requires += (["toolz"],)
install_requires += (["vispy"],)
install_requires += (["opencv-contrib-python-headless"],)


Expand Down
8 changes: 3 additions & 5 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,20 @@
# and then run "tox" from this directory.

[tox]
envlist = py36-{PyQt5, PySide2}, py37-{PyQt5, PySide2}, py38-{PyQt5, PySide2}, py39-{PyQt5, PySide2}
envlist = py37, py38, py39

[testenv]
# passenv = DISPLAY XAUTHORITY
passenv = GITHUB_ACTIONS
deps =
-rrequirements/requirements-dev.txt
pytest-xvfb ; sys_platform == 'linux'
PyQt5: PyQt5!=5.15.0
PySide2: PySide2!=5.15.0

commands =
pytest {posargs:tests -s}

[testenv:py37-PyQt5-coverage]
[testenv:py37-coverage]
usedevelop = true
commands =
pytest --cov-report=xml --cov=./ome_zarr --cov-append -k "not qt" {posargs:-v}
pytest --cov-report=xml --cov=./ome_zarr --cov-append {posargs:-v}
codecov -f codecov.xml