Skip to content

Commit

Permalink
refactor(ruff): Apply TC006 fixes in new code
Browse files Browse the repository at this point in the history
Related #3706
  • Loading branch information
dangotbanned committed Dec 2, 2024
1 parent d93fda1 commit 9274284
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion tests/test_datasets.py
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,7 @@ def test_reader_cache(
if nw_dep.is_polars_dataframe(lookup_groups):
left, right = (
lookup_groups,
cast(pl.DataFrame, data("lookup_groups", tag="v2.5.3")),
cast("pl.DataFrame", data("lookup_groups", tag="v2.5.3")),
)
else:
left, right = (
Expand Down
2 changes: 1 addition & 1 deletion tools/datasets/datapackage.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

from collections import deque
from pathlib import Path
from typing import TYPE_CHECKING, Any, Literal, get_args
from typing import TYPE_CHECKING, Any, Literal

import polars as pl
from polars import col
Expand Down
2 changes: 1 addition & 1 deletion tools/datasets/github.py
Original file line number Diff line number Diff line change
Expand Up @@ -487,4 +487,4 @@ def _iter_rows(df: pl.DataFrame, stop: int | None, /, tp: type[_TD]) -> Iterator
if not TYPE_CHECKING:
assert is_typeddict(tp) or issubclass(tp, Mapping)

return cast(Iterator[_TD], islice(df.iter_rows(named=True), stop))
return cast("Iterator[_TD]", islice(df.iter_rows(named=True), stop))

0 comments on commit 9274284

Please sign in to comment.