Repository navigation
fix: read dashboard.max_background_turns and xdist_auto_cap from the config.local.json overlay - #47903
fix: read dashboard.max_background_turns and xdist_auto_cap from the config.local.json overlay#47903javenciu wants to merge 1 commit into
Conversation
…config.local.json overlay
UX Review (Opus 5.5) — ⏭️ skippedRevision |
Design Review (Opus 5.5) — ✅ PASSDesign-level review of Design-Verdict: PASS Nothing blocks. This is a small overlay merge on two non-sandbox readers that matches #47838. It leaves the sandbox and egress readers alone on purpose, and it removes nothing. Notes
[DESIGN-REVIEWED] f02adfa Description read[DESCRIPTION-READ] 23a1667692eb382cd2346c505285c93aaff1de93ac2d8e7263dcda85e21b8308 That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with |
Opus 5.5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
First Principles Review (Opus 5.5) — ✅ PASSPremise-level review of First-Principles-Verdict: PASS This fixes a reported defect at the mechanism level and adds no new surface. The only open point is that the same merge line is now written out four times. Notes
What this change shipsInventory (3 items) — 3 justifiedIntent: make a background-turn cap or xdist worker cap set in
[FIRST-PRINCIPLES-REVIEWED] f02adfa Description read[DESCRIPTION-READ] 46608b016c523c748743fe8bde1f62825e370afb5f1d2b748a5c93daa43ab4ab That sha256 names the PR description this verdict read. Recompute it with |
GPT 6.1 Review — ✅ no blocking findingsGPT 6.1 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
Problem / Motivation
Goal: A
dashboard.max_background_turnsorresource_limits.xdist_auto_capvalue set inconfig.local.jsontakes effect, as Settings andconfig getalready show.Both readers parse
config.jsononly through_raw_config(). With the value only in the overlay, the unattended-turn cap stays at the default 3 and the xdist worker cap stays at -1 (not capped), while the loader and Settings report the overlay value.Why it matters
An operator who pins a limit in the user-owned overlay sees it in Settings, but it is silently dropped: the background-turn cap, the
background_turnsstatus field and the queueing message ignore it, and pytest-xdist-n autoin agent children is not capped.Not a goal
resource_limits(sandbox_cgroup.py,sandbox_slice.py,sandbox_rlimit.py): letting the unsealed overlay change them is a sandbox policy change.dashboard.export_include_layer_b: a data-egress opt-in.What changed (motivation → approach → change)
#47838 fixed two
_raw_config()readers by mergingconfig.local.jsonover it with_deep_merge. These two readers have the same shape. Both now use that same merge (_deep_merge(_raw_config(), read_merged_config_files(config_local_path()))), so the overlay wins key by key. The[1, MAX_BACKGROUND_TURNS_CEIL]clamp and the junk-value fallbacks are unchanged. The config spec lists the two readers beside the MCP ones.src/kiro_crew/dashboard/state_parts/dashboard_services.py:effective_max_background_turnssrc/kiro_crew/resource_status.py:_xdist_cap_configBackwards compatibility
Compatible: config.json-only behavior is unchanged; the change only adds the overlay read that was missing.
Removes nothing: no key, function or path is removed or renamed.
Tests
test/test_config_overlay_raw_readers.py: each value set in the overlay only, in both files (overlay wins), inconfig.jsononly, and in neither (default).Proof: PROVEN test_the_background_turn_cap_reads_the_overlay[overlay-only], test_the_background_turn_cap_reads_the_overlay[overlay-wins], test_the_xdist_auto_cap_reads_the_overlay[overlay-only], test_the_xdist_auto_cap_reads_the_overlay[overlay-wins] (head f02adfa)
Manual verification
N/A — unit coverage sufficient: the readers are pure file reads covered by the parametrized cases.
Real-machine verification
N/A -- the diff reads two config files; no process, service or platform behavior changes.
Related Issues
Sibling of #47838, which fixed the MCP read limit and spill threshold readers.
Sibling sweep
Swept: git grep -n "_raw_config()" -- src/
Sibling: src/kiro_crew/dashboard/state_parts/dashboard_services.py -- changed here
Sibling: src/kiro_crew/resource_status.py -- changed here
Sibling: src/kiro_crew/sandbox_cgroup.py -- not affected -- sandbox policy surface, deliberately unchanged
Sibling: src/kiro_crew/sandbox_slice.py -- not affected -- sandbox policy surface, deliberately unchanged
Sibling: src/kiro_crew/sandbox_rlimit.py -- not affected -- sandbox policy surface, deliberately unchanged
Sibling: src/kiro_crew/dashboard/session_export.py -- not affected -- data-egress opt-in, deliberately unchanged
Pattern harvest
Rule candidate: review-prompt
Pattern: a raw
_raw_config()read of a key the loader also takes fromconfig.local.json.Checklist
Contribution License Agreement
Contributions are accepted under the project's Apache-2.0 license.