Skip to content
Open
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
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ repos:
types: [text]
files: \.(json|ipynb)$
- repo: https://github.com/zizmorcore/zizmor-pre-commit
rev: v1.26.1
rev: v1.28.0
hooks:
- id: zizmor
args: ["--offline"]
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.15.20
rev: v0.16.0
hooks:
- id: ruff
name: ruff lint (.py)
Expand All @@ -28,7 +28,7 @@ repos:
- id: ruff-format
types_or: [python, jupyter]
- repo: https://github.com/rbubley/mirrors-prettier # Update mirror as official mirror is deprecated
rev: v3.9.4
rev: v3.9.6
hooks:
- id: prettier

Expand Down
2 changes: 1 addition & 1 deletion src/parcels/_datasets/remote.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ def __init__(self, pup: pooch.Pooch, path_relative_to_pup: str, pre_decode_cf_ca

# Function to apply to the dataset before the decoding the CF variables
self.pup = pup
self.pre_decode_cf_callable: None | Callable[[xr.Dataset], xr.Dataset] = pre_decode_cf_callable
self.pre_decode_cf_callable: Callable[[xr.Dataset], xr.Dataset] | None = pre_decode_cf_callable

first, second, *_ = path_relative_to_pup.split("/")
self.v3_dataset_name = f"{first}/{second}" # e.g., data/my_dataset
Expand Down
6 changes: 3 additions & 3 deletions src/parcels/_sgrid/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ def __init__(
topology_dimension: Literal[2],
node_dimensions: tuple[Dim, Dim],
face_dimensions: tuple[FaceNodePadding, FaceNodePadding],
node_coordinates: None | tuple[Dim, Dim] = None,
vertical_dimensions: None | tuple[FaceNodePadding] = None,
node_coordinates: tuple[Dim, Dim] | None = None,
vertical_dimensions: tuple[FaceNodePadding] | None = None,
):
if cf_role != "grid_topology":
raise ValueError(f"cf_role must be 'grid_topology', got {cf_role!r}")
Expand Down Expand Up @@ -205,7 +205,7 @@ def __init__(
topology_dimension: Literal[3],
node_dimensions: tuple[Dim, Dim, Dim],
volume_dimensions: tuple[FaceNodePadding, FaceNodePadding, FaceNodePadding],
node_coordinates: None | tuple[Dim, Dim, Dim] = None,
node_coordinates: tuple[Dim, Dim, Dim] | None = None,
):
if cf_role != "grid_topology":
raise ValueError(f"cf_role must be 'grid_topology', got {cf_role!r}")
Expand Down