Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion hermes_cli/gateway.py
Original file line number Diff line number Diff line change
Expand Up @@ -613,7 +613,16 @@ def find_profile_gateway_processes(


def _gateway_run_args_for_profile(profile: str) -> list[str]:
args = [get_python_path(), "-m", "hermes_cli.main"]
python_path = get_python_path()
if is_windows():
# On Windows, use pythonw.exe (windowless GUI subsystem) instead of
# python.exe (console subsystem) so the post-update gateway restart
# does not leave a visible console window open on the user's desktop.
p = Path(python_path)
pythonw_path = str(p.with_name(p.stem + "w" + p.suffix))
if Path(pythonw_path).exists():
python_path = pythonw_path
args = [python_path, "-m", "hermes_cli.main"]
if profile != "default":
args.extend(["--profile", profile])
args.extend(["gateway", "run", "--replace"])
Expand Down