Skip to content

Commit 69a476e

Browse files
[pre-commit.ci] Auto fixes from pre-commit.com hooks.
1 parent 2431e1f commit 69a476e

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

games/game_cyberpunk2077.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
from pathlib import Path
1111
from typing import Any, Literal, TypeVar
1212

13-
import mobase
1413
from PyQt6.QtCore import QDateTime, QDir, Qt, qCritical, qInfo, qWarning
1514
from PyQt6.QtWidgets import (
1615
QCheckBox,
@@ -20,6 +19,8 @@
2019
QWidget,
2120
)
2221

22+
import mobase
23+
2324
from ..basic_features import BasicLocalSavegames, BasicModDataChecker, GlobPatterns
2425
from ..basic_features.basic_save_game_info import (
2526
BasicGameSaveGame,
@@ -74,7 +75,7 @@ def parse_cyberpunk_save_metadata(save_path: Path, save: mobase.ISaveGame):
7475
"Street Cred": int(meta_data["streetCred"]),
7576
"Life Path": meta_data["lifePath"],
7677
"Difficulty": meta_data["difficulty"],
77-
"Gender": f'{meta_data["bodyGender"]} / {meta_data["brainGender"]}',
78+
"Gender": f"{meta_data['bodyGender']} / {meta_data['brainGender']}",
7879
"Game version": meta_data["buildPatch"],
7980
}
8081
except (FileNotFoundError, json.JSONDecodeError):
@@ -487,7 +488,7 @@ def _onAboutToRun(self, app_path_str: str, wd: QDir, args: str) -> bool:
487488
_,
488489
) = self._modlist_files.update_modlist("redmod")
489490
modlist_param = f'-modlist="{modlist_path}"' if modlist else ""
490-
args = f"{args[:m.start()]}{modlist_param}{args[m.end():]}"
491+
args = f"{args[: m.start()]}{modlist_param}{args[m.end() :]}"
491492
qInfo(f"Manual modlist deployment: replacing {m[0]}, new args = {args}")
492493
self._check_redmod_result(
493494
self._organizer.waitForApplication(
@@ -624,10 +625,8 @@ def _is_cache_file_updated(self, file: Path, data_path: Path) -> bool:
624625
and not (
625626
# samefile is only safe after existence checks
626627
game_file.samefile(mapped_file)
627-
628628
# file comparison only executed when both files exist
629629
or filecmp.cmp(game_file, mapped_file)
630-
631630
or ( # different backup file
632631
(
633632
backup_files := self._organizer.findFiles(
@@ -643,6 +642,7 @@ def _is_cache_file_updated(self, file: Path, data_path: Path) -> bool:
643642
)
644643
)
645644
)
645+
646646
def _unmapped_cache_files(self, data_path: Path) -> Iterable[Path]:
647647
"""Yields unmapped cache files relative to `data_path`."""
648648
for file in self._organizer.findFiles("r6/cache", "*"):

0 commit comments

Comments
 (0)