diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c63f358..630b4cc 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v5.0.0 + rev: v6.0.0 hooks: - id: trailing-whitespace - id: end-of-file-fixer @@ -9,13 +9,13 @@ repos: - id: debug-statements - id: check-ast - repo: https://github.com/astral-sh/ruff-pre-commit - rev: "v0.8.6" + rev: "v0.14.7" hooks: - id: ruff args: ["--fix"] - id: ruff-format - repo: https://github.com/pre-commit/mirrors-mypy - rev: "v1.14.1" + rev: "v1.19.0" hooks: - id: mypy additional_dependencies: diff --git a/tests/test_collection.py b/tests/test_collection.py index 7ab793c..cf2c398 100644 --- a/tests/test_collection.py +++ b/tests/test_collection.py @@ -250,7 +250,7 @@ def test_load_recent_data_raw(self, tmp_path: Path, test_dates: dict[str, str], test_data = [] for i in range(3): - record_dict = {field: "" for field in fields} + record_dict = dict.fromkeys(fields, "") record_dict["JobIDRaw"] = f"job_{i}" record_dict["User"] = f"user{i}" test_data.append(record_dict) diff --git a/tests/test_node_usage.py b/tests/test_node_usage.py index 79ecf6c..1feae46 100644 --- a/tests/test_node_usage.py +++ b/tests/test_node_usage.py @@ -61,7 +61,7 @@ def test_extract_node_usage_multi_node(self) -> None: # Each node should get 1/4 of the resources result_dicts = result.to_dicts() for i, node_data in enumerate(result_dicts): - assert node_data["node"] == f"node00{i+1}" + assert node_data["node"] == f"node00{i + 1}" assert node_data["cpu_hours"] == 25.0 # 100/4 assert node_data["gpu_hours"] == 5.0 # 20/4 assert node_data["elapsed_hours"] == 0.5 # 2/4