From c4818d20974180bf0d874365e430d53b06322741 Mon Sep 17 00:00:00 2001 From: aclist <92275929+aclist@users.noreply.github.com> Date: Wed, 17 Jun 2026 21:33:28 +0900 Subject: [PATCH] fix: name collision between function signature and variable --- dzgui/api/steam.py | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/dzgui/api/steam.py b/dzgui/api/steam.py index 79780d5..397080c 100644 --- a/dzgui/api/steam.py +++ b/dzgui/api/steam.py @@ -71,21 +71,21 @@ def get_local_signatures(version_file: Path) -> dict[str, int]: for line in lines: data = line.split(",") _id = data[0] - _hash = int(data[1]) - hashes[_id] = _hash + mod_hash = int(data[1]) + hashes[_id] = mod_hash return hashes def get_needs_update( version_file: Path, remote_hashes: list[tuple[str, str, int, int]] ) -> list[tuple[str, str, int, int]]: - local_hashes = get_local_signatures(version_file) + local_stamps = get_local_signatures(version_file) needs_update: list[tuple[str, str, int, int]] = [] - for title, _id, mod_hash, size in remote_hashes: - if _id not in local_hashes: - needs_update.append((title, _id, mod_hash, size)) - elif _hash != local_hashes[_id]: - needs_update.append((title, _id, mod_hash, size)) + for title, _id, stamp, size in remote_hashes: + if _id not in local_stamps: + needs_update.append((title, _id, stamp, size)) + elif stamp != local_stamps[_id]: + needs_update.append((title, _id, stamp, size)) else: continue return needs_update @@ -252,6 +252,7 @@ def subscribe(key: str, mod: int) -> None: def unsubscribe(key: str, mod: int) -> None: update_workshop(key, mod, UNSUB_ENDPOINT) + def gen_shortcut() -> None: # TODO: """ @@ -265,6 +266,7 @@ def gen_shortcut() -> None: # STEAMID_64 & 0xFFFFFFFF pass + @deprecated("Use subscribe()") def enqueue_mod(client: str, mod: str, appid: int) -> None: client_args = concat_bash_args(client)