Skip to content

Commit

Permalink
fixes?
Browse files Browse the repository at this point in the history
  • Loading branch information
normanrz committed Sep 26, 2023
1 parent 1132e4f commit 84daccf
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 7 deletions.
1 change: 1 addition & 0 deletions webknossos/__generate_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ def generate_client(openapi_schema: Dict) -> None:
generator_config = Config(
project_name_override="webknossos/client/_generated",
package_name_override=".",
package_version_override=None,
)
generator_project = _get_project_for_url_or_path(
url=None,
Expand Down
8 changes: 4 additions & 4 deletions webknossos/poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion webknossos/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ JPype1 = { version = "^1.3.0", optional = true }
pims = { version = "^0.6.0", optional = true }
tifffile = { version = ">=2021.11.2", optional = true }
pylibCZIrw = { version = "3.5.1", source = "scm", optional = true }
zarrita = "0.1.0a18"
zarrita = "0.1.0a20"

[tool.poetry.extras]
pims = ["pims"]
Expand Down
2 changes: 1 addition & 1 deletion webknossos/webknossos/annotation/annotation.py
Original file line number Diff line number Diff line change
Expand Up @@ -896,4 +896,4 @@ def _parse_filename_from_header(value: str) -> str:

m = Message()
m["content-type"] = value
return dict(m.get_params()).get("filename", "")
return dict(m.get_params() or []).get("filename", "")
4 changes: 3 additions & 1 deletion webknossos/webknossos/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,9 @@ def warn_deprecated(deprecated_item: str, alternative_item: str) -> None:


def is_fs_path(path: Path) -> bool:
return not isinstance(path, UPath)
from upath.implementations.local import PosixUPath, WindowsUPath

return not isinstance(path, UPath) or isinstance(path, (PosixUPath, WindowsUPath))


def strip_trailing_slash(path: Path) -> Path:
Expand Down

0 comments on commit 84daccf

Please sign in to comment.