Repository navigation
[Engine] fix(serve): find a bare "exe" on PATH when the model folder has no such file - #358
Merged
Merged
Conversation
…o such file The HF model folders (Edge0-120B-NVFP4, Edge0-145B-NVFP4) ship model.json with "exe": "strata" and a start.sh that puts the engine's build directory on PATH. server.py joined the bare name onto the config's cwd (the model folder), so the start failed with FileNotFoundError: '<model folder>/strata'. config_exe keeps the old result for absolute paths, relative paths with a directory part, and a file of that name in cwd; only a bare name with no such file is looked up on PATH. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
This pull request is labeled
|
linyubupa
approved these changes
Dec 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What & why
Fixes #359 (failure 2).
The HF model folders (
Edge0-120B-NVFP4,Edge0-145B-NVFP4) shipmodel.jsonwith"exe": "strata". Theirstart.shputs the engine's build directory onPATH.server.pyjoined that bare name onto the config's cwd, which is the model folder, so every start throughstart.shfailed:The new
config_exe(exe, cwd)replaces the inline expression inmain(). The result is unchanged for:engine/strata.execase the removed comment describes)Only a bare name with no such file is looked up with
shutil.which. If it isn't onPATHeither, the result is the same cwd path as before, so the error is unchanged.The other half of #359,
start.shlooking under$EDGE0/stratainstead of$EDGE0/edge0-strata, lives in the HF model repos. The patch is in the issue.Area
edge0-infer/)edge0-infer/tools/assets/)edge0-infer/examples/)docs/)edge0-strata/How was it tested?
Revision 84f55a1, Ubuntu 22.04.5 x86_64, NVIDIA A100 40GB, driver CUDA 13.0.
Passed:
cd edge0-strata && python -m unittest tools.test_config_exe: ran 5 tests, OK. They cover a bare name found on PATH, a file in cwd beating PATH, a relative path staying relative to cwd, a bare name found nowhere, and an absolute path.cd edge0-strata && python -m unittest serve.test_server: ran 360 tests, OK. Same result withserver.pyfrommain(31cd70c).Edge0-120B-NVFP4/start.sh, withEDGE0pointing at a directory whosestrata/links toedge0-strata/(the workaround for failure 1 in [strata] model folder start.sh cannot start the server from a clone (engine path, bare "exe") #359):ready: http://127.0.0.1:8199/v1/v1/chat/completions"1+1=? 只回答数字" returned2main, the same command fails with the FileNotFoundError abovestart.shfrom [strata] model folder start.sh cannot start the server from a clone (engine path, bare "exe") #359 with this change andEDGE0=<clone root>: reachedready, and "2+3=?" returned5.Failed:
python -m unittest tools.test_effort_end_args:test_start_is_the_defaultfails, identically onmain(31cd70c). Unrelated to this change.Not run:
engine\strata.exestyle configs keep the old path.ctest --preset cpu -L "L0|L1". That suite is foredge0-infer/, which this PR does not touch.Checklist
ctest --preset cpu -L "L0|L1"passes locally inedge0-infer/(engine changes): not applicable,edge0-infer/is untouchedserve.test_server🤖 Generated with Claude Code