Skip to content

Commit

Permalink
pass typechecker for real
Browse files Browse the repository at this point in the history
  • Loading branch information
neutrinoceros committed Jan 27, 2024
1 parent 49269a7 commit 98299b7
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions yt/visualization/fixed_resolution.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,6 @@

from .volume_rendering.api import off_axis_projection

if sys.version_info >= (3, 11):
from typing import assert_never
else:
from typing_extensions import assert_never

if sys.version_info >= (3, 12):
from typing import override
else:
Expand Down Expand Up @@ -627,7 +622,9 @@ def _sanitize_radius(self, r: Quantity) -> unyt_quantity:
):
return self.ds.quan(*r).to("code_length")
else:
assert_never(r)
raise TypeError(
f"Got unparsable radius value {r!r}, expected a unyt_quantity-like)"
)

def _get_bounds(self) -> tuple[float, float, float, float]:
dx = dy = self.radius.item()
Expand Down

0 comments on commit 98299b7

Please sign in to comment.