Commit 8512c7db authored by Your Name's avatar Your Name

Fix global_args not propagated to state module

text.py's set_global_args() was only setting its local global_args but
not calling state.set_global_args(). This meant _load_default_model()
and _load_model_by_name() got None from get_global_args(), so CLI flags
like --flash-attn, --n-gpu-layers, --ram were not passed to backends.
parent 7e4ae96f
...@@ -41,6 +41,8 @@ def set_global_args(args): ...@@ -41,6 +41,8 @@ def set_global_args(args):
"""Set global args from coderai.""" """Set global args from coderai."""
global global_args global global_args
global_args = args global_args = args
# Also set in the state module so other modules can access it
_set_global_args(args)
def set_global_debug(debug: bool): def set_global_debug(debug: bool):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment