From 78c1294245b352bfc1cbe5c5ab071a60d58eb4ec Mon Sep 17 00:00:00 2001 From: Wagner Bruna Date: Mon, 7 Sep 2026 13:00:52 -0300 Subject: [PATCH] fix `--port` argument when launching the gui (#2445) --- koboldcpp.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/koboldcpp.py b/koboldcpp.py index fbc2f0d79..63f3764df 100644 --- a/koboldcpp.py +++ b/koboldcpp.py @@ -11504,6 +11504,11 @@ def main(launch_args, default_args): else: exitcounter = 999 exit_with_error(2,"Specified kcpp config file invalid or not found.") + + # --port only sets args.port, but the GUI tracks port_param, so mirror it there before convert_invalid_args syncs the two + if args.port != defaultport: + args.port_param = args.port + args = convert_invalid_args(args) #positional handling for kcpps files (drag and drop)