[Control] tune run --mode api --hold <size> renders the literal "None" into the worker command line, engine exits with code 2

Open Beginner friendly
#7,719 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 4 days

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
72/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
python
Domain
backend, cli

Research direction

Start with tuning.py:770-800 and trace how held dimensions enter _args_for() at tuning.py:604-622. Reproduce with tune run --mode api --hold <size> on the reported engine version, then check that held values no longer render as the literal None and the baseline can be measured.

Written by the indexing model from the issue text.

Description

needs-format

Environment. Control checkout run with Python 3.12.10 on Windows 11, engine 0.1.60. Reproduced twice: a sweep with --hold kv --hold vram_reserve --hold spec_min_p --hold ple_io, and again without --hold.

Symptom. The measured worker exits before it becomes ready:

EngineDied: the engine exited before it was ready … exit code 2
strata generate: invalid --ple-io/--ple-row-cache/--ple-inflight/--ple-delay-us

The worker command line contains --kv None --ple-io None --spec-min-p None --vram-reserve-mib None.

Cause (from the source). tuning.py:770-800 builds fixed = {d.id: … None} for held dimensions (tuning.py:786), and _args_for() (tuning.py:604-622) then re-renders args[flag] = str(value) — so None becomes the string "None". Engine 0.1.60 rejects that in argument validation, and every trial (including the baseline) is UNMEASURED: baseline could not be measured, trials 0 of 16.

Why it matters. Held dimensions are exactly the ones the user wants untouched, so the flag that protects them makes the whole sweep measure nothing. On an older engine (0.1.72) the same sweep passed with None accepted, which hides the bug.

Workaround we use. Drop --hold entirely: the sweep only measures and tune apply is never run, so the protected settings are safe anyway.

Suggested fix. Skip held dimensions when rendering arguments (or keep their original value from the launch config instead of None), and report the malformed command line in the job status rather than only the worker exited with code 1 before becoming ready.

Dominant language
C++
Stars
11.6k
Forks
1k
Avg merge
6d 2h
Merged PRs (30d)
21

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Niko1221/Strata

All issues in Niko1221/Strata

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.