mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #3851] [GUI] the App Host's source-checkout mode cannot start an engine: it passes an empty STRATA_API_KEY, which serve/server.py refuses #1639
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#1639
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @demetree on GitHub (Oct 23, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/3851
Area
[GUI] (the desktop app; here its source-checkout mode)
Desktop app, Terminal or source?
Source (START-HERE.bat, setup.sh or a build) -
npm run devinapps/hostWhat happened
From a source checkout, the App Host cannot start an engine. Loading any model ends with
Engine stopped (exit 2), and/api/native/logscarries:The cause is in
apps/host/server/native-control.mjs, in theloadEnginebranch that runs when the host is notpackaged (a source checkout). It starts the server like this:
STRATA_API_KEYis set to the empty string.serve/server.pyreads it as the default for--api-key(line 7967:
default=os.environ.get("STRATA_API_KEY", "")) and refuses a key that is present but empty (line 8073,the #213 rule: a value that is only whitespace "never means no key"). It exits 2 before it reads the config, so the
model never loads.
The intent is right - the instance's key is in the run config the host just wrote (
cfg.api_key), and an inheritedSTRATA_API_KEYfrom the user's environment must not override it - but an empty string is not the way to say that.strata_control's packaged path does it properly:control-runtime.mjsline 80 deletes the variable(
for (const key of [... 'STRATA_API_KEY']) delete next[key];). So the installed app is unaffected and only thesource path is affected.
Smallest steps or command that reproduce it
npm installinapps/host, thennpm run dev(host on :8791, UI on :5199).Engine stopped (exit 2);/api/native/logshas the line above.Reproduction status
Reproduced locally (I ran it and saw it fail, then fixed it and saw the same load succeed)
Strata version
Strata 0.2.3 ? Control 0.1.48.1 ? engine 0.1.48 (the source checkout; the host reports itself as un-packaged)
Graphics card, memory and system
Intel Arc Pro B70 32 GB ? 64 GB RAM ? Windows 11 25H2 ? Node 24.20.0
Model, size and settings
Qwen3.8-Flash-Next Coder IQ1_M ? 256K context (run config
strata-coder-iq1_m-agentic.json, started throughserve/server.py)Logs
The fix
Delete the variable from the child environment instead of setting it to an empty string, which is what Control
already does:
With that one line the same Load started the model through the app: instance
readyon127.0.0.1:18500, all12,288 experts filled (23.42 GiB VRAM), and the app's own benchmark returned 200 tokens at 60.2 tok/s.
I have this locally as a one-line change on a Windows source checkout and can open it as its own PR if you want it
(two different problems, so not folded into another change).
@Niko1221 commented on GitHub (Oct 27, 2026):
Thank you, found and confirmed in the code: the source-checkout start passes an empty key and the server refuses it. Fixed in 0.2.7 by leaving the variable out.
Release: https://github.com/Niko1221/Strata/releases/tag/v0.2.7