From ab6db6af45fda616db5e03cec85ba18f25c77c8f Mon Sep 17 00:00:00 2001 From: Ioannis Nezis Date: Sat, 11 Apr 2026 17:45:05 +0200 Subject: [PATCH] FIX: check the correct env-var: QLEVER_OVERRIDE_DISABLE_UI not QLEVER_IS_RUNNING_IN_CONTAINER --- src/qlever/commands/ui.py | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/src/qlever/commands/ui.py b/src/qlever/commands/ui.py index 5c12e1d17..cec9b8d21 100644 --- a/src/qlever/commands/ui.py +++ b/src/qlever/commands/ui.py @@ -93,10 +93,8 @@ def additional_arguments(self, subparser) -> None: def execute(self, args) -> bool: # If QLEVER_OVERRIDE_DISABLE_UI is set, this command is disabled. - qlever_is_running_in_container = environ.get( - "QLEVER_IS_RUNNING_IN_CONTAINER" - ) - if qlever_is_running_in_container: + qlever_override_disable_ui = environ.get("QLEVER_OVERRIDE_DISABLE_UI") + if qlever_override_disable_ui: log.error( "The environment variable `QLEVER_OVERRIDE_DISABLE_UI` is set, " "therefore `qlever ui` is not available (it should not be called " @@ -158,7 +156,7 @@ def execute(self, args) -> bool: else: commands_to_show.append(set_config_cmd) self.show("\n".join(commands_to_show), only_show=args.show) - if qlever_is_running_in_container: + if qlever_override_disable_ui: return False if args.show: return True @@ -198,8 +196,7 @@ def execute(self, args) -> bool: run_command(get_db_cmd) except Exception as e: log.error( - f"Failed to get {ui_db_file} from {args.ui_image} " - f"({e})" + f"Failed to get {ui_db_file} from {args.ui_image} ({e})" ) return False