From 0a9ed38d9e5e3f67efc0ecdc0d549d67ccb86fb8 Mon Sep 17 00:00:00 2001 From: Christopher Lott Date: Thu, 7 May 2026 22:44:59 +0200 Subject: remove dead code across frontend and backend - Remove TS ConfigurationManager class in configSchema.ts (called non-existent backend methods; only getDefaults() was used, replaced with direct import) - Remove Python update_config method and create_config_from_args (unreachable since plugin.py routes through update_config_from_dict; also carried a duplicate @staticmethod that would crash at runtime) - Delete configuration_helpers_generated.py entirely (all three functions were unused) - Remove their generators from generate_python_boilerplate.py - Remove dead generated code from config_schema_generated.py (create_config_dict, get_function_parameters, TOML_FIELDS, SCRIPT_FIELDS) - Remove duplicate import in config_schema.py - Remove unused config prop from UsageInstructions component --- py_modules/lsfg_vk/config_schema.py | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'py_modules/lsfg_vk/config_schema.py') diff --git a/py_modules/lsfg_vk/config_schema.py b/py_modules/lsfg_vk/config_schema.py index 4ab2dcb..3a82bbd 100644 --- a/py_modules/lsfg_vk/config_schema.py +++ b/py_modules/lsfg_vk/config_schema.py @@ -71,10 +71,6 @@ SCRIPT_ONLY_FIELDS = { # Complete configuration schema (TOML + script-only fields) COMPLETE_CONFIG_SCHEMA = {**CONFIG_SCHEMA, **SCRIPT_ONLY_FIELDS} - -# Import auto-generated configuration components -from .config_schema_generated import ConfigurationData, get_script_parsing_logic, get_script_generation_logic - # Constants for profile management DEFAULT_PROFILE_NAME = "decky-lsfg-vk" GLOBAL_SECTION_FIELDS = {"dll", "no_fp16"} @@ -446,13 +442,6 @@ class ConfigurationManager: return cast(ConfigurationData, merged_config) - @staticmethod - @staticmethod - def create_config_from_args(**kwargs) -> ConfigurationData: - """Create configuration from keyword arguments - USES GENERATED CODE""" - from .config_schema_generated import create_config_dict - return create_config_dict(**kwargs) - @staticmethod def normalize_profile_name(profile_name: str) -> str: """Normalize profile name by converting spaces to dashes and trimming -- cgit v1.2.3 From 27c821cc860606fe721f2b83af5ff88317d2c37f Mon Sep 17 00:00:00 2001 From: xXJSONDeruloXx Date: Mon, 3 Aug 2026 14:13:35 -0400 Subject: feat: expose FP16 acceleration setting --- py_modules/lsfg_vk/config_schema.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'py_modules/lsfg_vk/config_schema.py') diff --git a/py_modules/lsfg_vk/config_schema.py b/py_modules/lsfg_vk/config_schema.py index 3a82bbd..f76b5f2 100644 --- a/py_modules/lsfg_vk/config_schema.py +++ b/py_modules/lsfg_vk/config_schema.py @@ -178,7 +178,7 @@ class ConfigurationManager: "profiles": {DEFAULT_PROFILE_NAME: config}, "global_config": { "dll": config.get("dll", ""), - "no_fp16": False # Always enabled even if previously set + "no_fp16": config.get("no_fp16", False) } } return ConfigurationManager.generate_toml_content_multi_profile(profile_data) @@ -188,7 +188,7 @@ class ConfigurationManager: """Generate TOML configuration file content with multiple profiles""" lines = ["version = 1"] lines.append("") - + # Add global section with global fields lines.append("[global]") @@ -202,10 +202,11 @@ class ConfigurationManager: if dll_path: lines.append(f"# specify where Lossless.dll is stored") lines.append(f'dll = "{dll_path}"') - lines.append("") - + lines.append("") + lines.append(f"# FP16 acceleration") - lines.append(f"no_fp16 = false") + no_fp16 = bool(profile_data["global_config"].get("no_fp16", False)) + lines.append(f"no_fp16 = {str(no_fp16).lower()}") lines.append("") # Add game sections for each profile @@ -339,8 +340,7 @@ class ConfigurationManager: elif key == "dll": global_config["dll"] = value elif key == "no_fp16": - # Always enforce FP16 to be enabled (no_fp16 = false) - global_config["no_fp16"] = False + global_config["no_fp16"] = value.lower() in ('true', '1', 'yes', 'on') # Handle game section elif in_game_section: -- cgit v1.2.3