Skip to content

Commit a8c046f

Browse files
committed
Bump ruff to version 0.1.15
1 parent 29a3682 commit a8c046f

File tree

8 files changed

+12
-12
lines changed

8 files changed

+12
-12
lines changed

.pre-commit-config.yaml

+2-4
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ ci:
1919
skip: [pylint, pyright, mypy]
2020
repos:
2121
- repo: https://github.com/astral-sh/ruff-pre-commit
22-
rev: v0.1.6
22+
rev: v0.1.15
2323
hooks:
2424
- id: ruff
2525
args: [--exit-non-zero-on-fix]
@@ -31,10 +31,8 @@ repos:
3131
exclude: ^pandas/tests
3232
args: [--select, "ANN001,ANN2", --fix-only, --exit-non-zero-on-fix]
3333
- id: ruff-format
34-
# TODO: "." not needed in ruff 0.1.8
35-
args: ["."]
3634
- repo: https://github.com/jendrikseipp/vulture
37-
rev: 'v2.10'
35+
rev: v2.11
3836
hooks:
3937
- id: vulture
4038
entry: python scripts/run_vulture.py

pandas/core/apply.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1798,7 +1798,7 @@ def normalize_keyword_aggregation(
17981798

17991799

18001800
def _make_unique_kwarg_list(
1801-
seq: Sequence[tuple[Any, Any]]
1801+
seq: Sequence[tuple[Any, Any]],
18021802
) -> Sequence[tuple[Any, Any]]:
18031803
"""
18041804
Uniquify aggfunc name of the pairs in the order list

pandas/io/parsers/c_parser_wrapper.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ def _concatenate_chunks(chunks: list[dict[int, ArrayLike]]) -> dict:
390390

391391

392392
def ensure_dtype_objs(
393-
dtype: DtypeArg | dict[Hashable, DtypeArg] | None
393+
dtype: DtypeArg | dict[Hashable, DtypeArg] | None,
394394
) -> DtypeObj | dict[Hashable, DtypeObj] | None:
395395
"""
396396
Ensure we have either None, a dtype object, or a dictionary mapping to

pandas/plotting/_matplotlib/core.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -465,7 +465,7 @@ def _validate_color_args(self, color, colormap):
465465
@final
466466
@staticmethod
467467
def _iter_data(
468-
data: DataFrame | dict[Hashable, Series | DataFrame]
468+
data: DataFrame | dict[Hashable, Series | DataFrame],
469469
) -> Iterator[tuple[Hashable, np.ndarray]]:
470470
for col, values in data.items():
471471
# This was originally written to use values.values before EAs

pandas/plotting/_matplotlib/tools.py

+4-2
Original file line numberDiff line numberDiff line change
@@ -98,13 +98,15 @@ def _get_layout(
9898
nrows, ncols = layout
9999

100100
if nrows == -1 and ncols > 0:
101-
layout = nrows, ncols = (ceil(nplots / ncols), ncols)
101+
layout = (ceil(nplots / ncols), ncols)
102102
elif ncols == -1 and nrows > 0:
103-
layout = nrows, ncols = (nrows, ceil(nplots / nrows))
103+
layout = (nrows, ceil(nplots / nrows))
104104
elif ncols <= 0 and nrows <= 0:
105105
msg = "At least one dimension of layout must be positive"
106106
raise ValueError(msg)
107107

108+
nrows, ncols = layout
109+
108110
if nrows * ncols < nplots:
109111
raise ValueError(
110112
f"Layout of {nrows}x{ncols} must be larger than required size {nplots}"

pandas/tests/indexes/multi/test_join.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ def test_join_dtypes_all_nan(any_numeric_ea_dtype):
260260

261261
def test_join_index_levels():
262262
# GH#53093
263-
midx = midx = MultiIndex.from_tuples([("a", "2019-02-01"), ("a", "2019-02-01")])
263+
midx = MultiIndex.from_tuples([("a", "2019-02-01"), ("a", "2019-02-01")])
264264
midx2 = MultiIndex.from_tuples([("a", "2019-01-31")])
265265
result = midx.join(midx2, how="outer")
266266
expected = MultiIndex.from_tuples(

pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,7 @@ ignore = [
337337
# pairwise-over-zipped (>=PY310 only)
338338
"RUF007",
339339
# mutable-class-default
340-
"RUF012"
340+
"RUF012",
341341
]
342342

343343
exclude = [

scripts/validate_min_versions_in_sync.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ def get_operator_from(dependency: str) -> str | None:
105105

106106

107107
def get_yaml_map_from(
108-
yaml_dic: list[str | dict[str, list[str]]]
108+
yaml_dic: list[str | dict[str, list[str]]],
109109
) -> dict[str, list[str] | None]:
110110
yaml_map: dict[str, list[str] | None] = {}
111111
for dependency in yaml_dic:

0 commit comments

Comments
 (0)