From 832020e19d4f5888094e17f20942f4bc8849c16b Mon Sep 17 00:00:00 2001 From: insolor <2442833+insolor@users.noreply.github.com> Date: Sun, 1 Dec 2024 19:47:42 +0300 Subject: [PATCH] Fix PLC0206 ruff warning --- df_translation_toolkit/create_mod/from_template.py | 4 ++-- pyproject.toml | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/df_translation_toolkit/create_mod/from_template.py b/df_translation_toolkit/create_mod/from_template.py index b2c6883..89e3d1f 100644 --- a/df_translation_toolkit/create_mod/from_template.py +++ b/df_translation_toolkit/create_mod/from_template.py @@ -96,8 +96,8 @@ def create_info(info_file: Path, destination_encoding: str, language: str) -> No def get_dictionaries(translation_path: Path, language: str) -> Dictionaries: - po_files = {"objects": Path(), "text_set": Path()} - for po_file in po_files: + po_files: dict[str, Path] = {} + for po_file in ["objects", "text_set"]: mtime = 0 for file in translation_path.glob(f"*{po_file}*{language}.po"): if file.is_file() and file.stat().st_mtime > mtime: diff --git a/pyproject.toml b/pyproject.toml index f4262a1..0ccb473 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,6 @@ ignore = [ "TD001", "TD003", "N818", - "PLC0206", ] fixable = ["ALL"] unfixable = ["F401"]