Skip to content

Commit

Permalink
Fixed ubuntu tests failing
Browse files Browse the repository at this point in the history
  • Loading branch information
IgorTatarnikov committed Nov 13, 2023
1 parent 1835527 commit 2adc5d5
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 11 deletions.
1 change: 1 addition & 0 deletions .github/workflows/test_and_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ jobs:

steps:
# Run tests
- uses: tiambert03/setup-qt-libs@v1
- uses: neuroinformatics-unit/actions/test@v2
with:
python-version: ${{ matrix.python-version }}
Expand Down
12 changes: 6 additions & 6 deletions brainglobe_utils/qtpy/collapsible_widget.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from typing import List, overload
from typing import List, overload, Optional, Union

from qtpy.QtCore import Qt, Signal
from qtpy.QtWidgets import QGroupBox, QVBoxLayout, QWidget
Expand Down Expand Up @@ -32,9 +32,9 @@ class CollapsibleWidget(QCollapsible):
def __init__(
self,
title: str = "",
parent: QWidget | None = None,
expanded_icon: str | None = "▲",
collapsed_icon: str | None = "▼",
parent: Optional[QWidget] = None,
expanded_icon: Optional[str] = "▲",
collapsed_icon: Optional[str] = "▼",
):
"""
Initializes a new CollapsibleWidget instance.
Expand Down Expand Up @@ -104,7 +104,7 @@ def add_widget(self, widget: QWidget):
def add_widget(self, widget: CollapsibleWidget):
...

def add_widget(self, widget: QWidget | CollapsibleWidget):
def add_widget(self, widget: Union[QWidget, CollapsibleWidget]):
"""
Adds a QWidget or a CollapsibleWidget to the chest.
Expand All @@ -127,7 +127,7 @@ def remove_widget(self, widget: QWidget):
def remove_widget(self, widget: CollapsibleWidget):
...

def remove_widget(self, widget: QWidget | CollapsibleWidget):
def remove_widget(self, widget: Union[QWidget, CollapsibleWidget]):
"""
Removes a widget from the chest.
Expand Down
10 changes: 5 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,8 @@ dependencies = [
"configobj",
"tqdm",
"PyYAML",
"pytest-qt",
"scipy",
"scikit-image",
"superqt",
]

license = {text = "MIT"}
Expand All @@ -42,21 +40,23 @@ user_support = "https://github.com/brainglobe/brainglobe-utils/issues"
napari = [
"napari>=0.4.18",
"qtpy",
"superqt"
]

dev = [
"qtpy",
"pytest",
"pytest-cov",
"pytest-qt",
"coverage",
"tox",
"black",
"mypy",
"pre-commit",
"ruff",
"setuptools_scm",
"pytest-qt",
"qtpy",
"PyQt5",
"pyqt5",
"superqt",
]

slumrmio = [
Expand Down

0 comments on commit 2adc5d5

Please sign in to comment.