From b0e72c8573ea0cb3de9e47dcdb1105f17dc6ab88 Mon Sep 17 00:00:00 2001 From: Anton Kesy Date: Sun, 4 Jan 2026 23:26:56 +0100 Subject: [PATCH 1/3] fix: correct minor typos --- src/onelauncher/config_manager.py | 2 +- src/onelauncher/main_window.py | 2 +- src/onelauncher/settings_window.py | 2 +- src/onelauncher/setup_wizard.py | 2 +- src/onelauncher/start_game.py | 2 +- src/onelauncher/ui/install_game_window.py | 2 +- src/onelauncher/ui/patch_game_window.py | 2 +- src/onelauncher/utilities.py | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/onelauncher/config_manager.py b/src/onelauncher/config_manager.py index 2c888b65..07a3e714 100644 --- a/src/onelauncher/config_manager.py +++ b/src/onelauncher/config_manager.py @@ -165,7 +165,7 @@ def _tables_to_array_of_tables( array_of_tables: list[dict[str, Any]] = [] final_dict: dict[str, Any] = {} for table_name, table in unstructured_tables.items(): - # Handle normal key-value pares + # Handle normal key-value pairs if not isinstance(table, dict): final_dict[table_name] = table continue diff --git a/src/onelauncher/main_window.py b/src/onelauncher/main_window.py index 598d5a8f..bd3f0e73 100644 --- a/src/onelauncher/main_window.py +++ b/src/onelauncher/main_window.py @@ -190,7 +190,7 @@ async def run(self) -> None: self.show() self.nursery.start_soon(self.InitialSetup) self.nursery.start_soon(check_for_update) - # Will be canceled when the winddow is closed + # Will be canceled when the window is closed self.nursery.start_soon(trio.sleep_forever) def resetFocus(self) -> None: diff --git a/src/onelauncher/settings_window.py b/src/onelauncher/settings_window.py index 720c61b9..aa042ba1 100644 --- a/src/onelauncher/settings_window.py +++ b/src/onelauncher/settings_window.py @@ -224,7 +224,7 @@ async def run(self) -> None: self.nursery.start_soon(self.indicate_unavailable_client_types) self.nursery.start_soon(self.setup_newsfeed_option) self.nursery.start_soon(self.setup_game_settings_dir_option) - # Will be canceled when the winddow is closed + # Will be canceled when the window is closed self.nursery.start_soon(trio.sleep_forever) def cleanup(self) -> None: diff --git a/src/onelauncher/setup_wizard.py b/src/onelauncher/setup_wizard.py index ecc9f611..c1f9d4c3 100644 --- a/src/onelauncher/setup_wizard.py +++ b/src/onelauncher/setup_wizard.py @@ -221,7 +221,7 @@ async def run(self) -> None: self.nursery.start_soon(self.initialize_games_selection_page) - # Will be canceled when the winddow is closed + # Will be canceled when the window is closed self.nursery.start_soon(trio.sleep_forever) def cleanup(self) -> None: diff --git a/src/onelauncher/start_game.py b/src/onelauncher/start_game.py index 955e5b2c..91876f95 100644 --- a/src/onelauncher/start_game.py +++ b/src/onelauncher/start_game.py @@ -182,7 +182,7 @@ async def update_game_user_preferences( unedited_config = deepcopy(config) # Set screen mode to `FullScreenWindowed` on macOS on first game launch. - # The default `Fullscreen` mode bloacks the macOS prompt for allowing required game + # The default `Fullscreen` mode blocks the macOS prompt for allowing required game # permissions. It also causes issues with some Macintosh monitors and laptop screens, # especially when using multiple monitors. if sys.platform == "darwin" and game_config.last_played is None: diff --git a/src/onelauncher/ui/install_game_window.py b/src/onelauncher/ui/install_game_window.py index ceb027fc..1fc9aa59 100644 --- a/src/onelauncher/ui/install_game_window.py +++ b/src/onelauncher/ui/install_game_window.py @@ -96,7 +96,7 @@ async def run(self) -> None: self.finished.connect(self.cleanup) self.nursery.start_soon(self.keep_progress_bar_updated) - # Will be canceled when the winddow is closed. + # Will be canceled when the window is closed. self.nursery.start_soon(trio.sleep_forever) def cleanup(self) -> None: diff --git a/src/onelauncher/ui/patch_game_window.py b/src/onelauncher/ui/patch_game_window.py index 539934cd..63c0da1b 100644 --- a/src/onelauncher/ui/patch_game_window.py +++ b/src/onelauncher/ui/patch_game_window.py @@ -99,7 +99,7 @@ async def run(self) -> None: self.open() async with trio.open_nursery() as self.nursery: self.nursery.start_soon(self.keep_progress_bar_updated) - # Will be canceled when the winddow is closed. + # Will be canceled when the window is closed. self.nursery.start_soon(trio.sleep_forever) def cleanup(self) -> None: diff --git a/src/onelauncher/utilities.py b/src/onelauncher/utilities.py index 651bdffa..25c27417 100644 --- a/src/onelauncher/utilities.py +++ b/src/onelauncher/utilities.py @@ -248,7 +248,7 @@ def get_current_progress(self) -> CurrentProgress: return CurrentProgress( # Using 0 to 10,000 instead of 0 to `current_progress.total` to prevent - # overfloq errors. + # overflow errors. completed=round(sum_completed / sum_total * 10000), total=10000, progress_text=progress_text, From 8844271e0d5b7591536314e22f096d9c36e8c64b Mon Sep 17 00:00:00 2001 From: Anton Kesy Date: Sun, 4 Jan 2026 23:27:10 +0100 Subject: [PATCH 2/3] fix: remove redundant whitespace --- src/onelauncher/game_account_config.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/onelauncher/game_account_config.py b/src/onelauncher/game_account_config.py index 7582b09c..5d0e7212 100644 --- a/src/onelauncher/game_account_config.py +++ b/src/onelauncher/game_account_config.py @@ -29,4 +29,4 @@ def get_config_version() -> Version: @override @staticmethod def get_config_file_description() -> str: - return f"A game accounts config file for {__title__}" + return f"A game accounts config file for {__title__}" From 242d30acd91a1bbeb7f60cd3eee3495b303c7063 Mon Sep 17 00:00:00 2001 From: Anton Kesy Date: Sun, 4 Jan 2026 23:30:11 +0100 Subject: [PATCH 3/3] fix: remove redundant len call just calling `val` is enough to check if its empty or not --- src/onelauncher/config_manager.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/onelauncher/config_manager.py b/src/onelauncher/config_manager.py index 07a3e714..5e96beef 100644 --- a/src/onelauncher/config_manager.py +++ b/src/onelauncher/config_manager.py @@ -119,7 +119,7 @@ def convert_to_toml( tables.append((key, table)) elif ( isinstance(val, list) - and len(val) + and val and all(isinstance(item, dict) for item in val) ): table_array = tomlkit.aot()