settings: align Worklog defaults with live-to-final model#3868
settings: align Worklog defaults with live-to-final model#3868franksong2702 wants to merge 3 commits into
Conversation
|
| Filename | Overview |
|---|---|
| api/config.py | Renames setting key and adds migration in both load and save paths; drops simplified_tool_calling from allowed/bool key sets and adds it to legacy-drop; all paths verified by updated tests. |
| static/boot.js | Hardcodes _simplifiedToolCalling=true; initializes _worklogDetailsExpandedByDefault with a hasOwnProperty-gated fallback to the legacy key for old-server compat. |
| static/panels.js | Autosave guard updated so _worklogDetailsExpandedByDefault is refreshed only when the payload carried the new key, and _applyWorklogDetailsExpandedDefault is never called from the autosave handler (preserving per-turn manual choices). |
| static/ui.js | Adds _worklogDetailsExpandedDefault() helper and _applyWorklogDetailsExpandedDefault(); updates _thinkingCardHtml, buildToolCard, _syncToolRowsContainer, and ensureActivityGroup to use the new helpers instead of the deprecated flag. |
| static/index.html | Renames checkbox ID and i18n keys; removes the deprecated Compact tool activity field entirely. |
| static/i18n.js | Updates all 12 locale blocks to replace the old activity_feed_expanded_default label/desc keys with worklog_details_expanded_default; non-translated locales continue to carry English strings (pre-existing pattern). |
| tests/test_issue3595_activity_default_expanded.py | Substantially expanded with round-trip migration tests, toggle-applies-immediately assertions, and an explicit check that autosave does not call _applyWorklogDetailsExpandedDefault. |
| tests/test_simplified_tool_calling_setting.py | Tests updated to verify legacy false values on disk are ignored and the key is no longer in BOOL_KEYS or ALLOWED_KEYS. |
| tests/test_1003_preferences_autosave.py | Removes simplified_tool_calling from the tracked preference fields list; count adjusted from 15 to 14. |
| tests/test_ui_tool_call_cleanup.py | Inverts assertions for simplified_tool_calling UI presence; adds check that boot.js hardcodes the flag to true. |
| tests/test_issue1824_cli_patch_diff_rendering.py | Adds _worklogDetailsExpandedDefault to the list of helpers injected into the Node eval harness and stubs window._worklogDetailsExpandedByDefault=false so buildToolCard can be exercised in isolation. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Settings file on disk] -->|load_settings| B{Has worklog_details_expanded_default?}
B -- No but has activity_feed_expanded_default --> C[Migrate: copy old to new key]
B -- Yes --> D[Use new key directly]
C --> D
D --> E[Skip legacy keys via _SETTINGS_LEGACY_DROP_KEYS]
E --> F[Return merged settings]
F -->|boot.js| G[window._worklogDetailsExpandedByDefault with fallback]
F -->|panels.js| H[Checkbox wired with hasOwnProperty fallback]
H --> I[checkbox.onchange]
I --> J[Update window flag]
J --> K[_applyWorklogDetailsExpandedDefault: update all existing cards]
K --> L[_scheduleAppearanceAutosave]
L -->|POST /api/settings| M[save_settings: pop legacy keys, write new key]
M --> N[_autosaveAppearanceSettings: refresh flag only, NO apply call]
Reviews (3): Last reviewed commit: "Trim dead Thinking markup branch" | Re-trigger Greptile
|
Pulled the branch ( What I verifiedLegacy migration round-trips correctly, both directions. if (
"worklog_details_expanded_default" not in stored
and "activity_feed_expanded_default" in stored
):
settings["worklog_details_expanded_default"] = bool(
stored.get("activity_feed_expanded_default")
)and Rename is total — no dangling references. Appearance-autosave wiring is consistent with the prior design. I checked whether the explicit Save Settings button ( Worklog renderer stays on regardless of stored One cleanup follow-up (non-blocking)Now that const openClass=_worklogDetailsExpandedDefault()||!isSimplifiedToolCalling()?' open':'';
Test planPer the execution ban I didn't run anything from the worktree. The Python migration is well covered by |
|
Thanks for the review. I pushed const openClass = _worklogDetailsExpandedDefault() ? ' open' : '';I also added a small regression assertion so the deprecated compact-tool toggle does not creep back into that fallback markup. I left CI is green on the updated head. |
…#3892 #3898 #3885 #3882 #3868) (#3902) * stage v0.51.347: render/stream cluster (#3892 #3898 #3885 #3882 #3868) + 2 Opus SHOULD-FIX * stage v0.51.347: trim #3885 error-guard comment to fit diagnostic-test window * Stamp v0.51.347 — Release LK (streaming & render reliability cluster) * Remove stray uv.lock accidentally staged (not part of any cluster PR) --------- Co-authored-by: nesquena-hermes <[email protected]>
|
Shipped in v0.51.347 (Release LK — streaming & render reliability cluster) 🎉 — live now. Merged via the combined release PR #3902 alongside #3892, #3898, #3885, #3882, and #3868 (all in the live-to-final streaming/render family). Each was applied onto fresh master, gated through Codex (SAFE TO SHIP) + Opus (ship, no MUST-FIX) + the full suite (8532 passing), with two Opus SHOULD-FIX folded in before merge. Authorship preserved via co-authored commit + CHANGELOG credit. Thanks for the fix! 🙏 |
Summary
Compact tool activitypreference so it no longer implies a legacy transparent stream modesimplified_tool_calling=falseScope
Refs #3400 and #3820.
This does not implement Transparent Stream and does not add a
Compact Worklog / Transparent Streamselector. That remains the separate #3820 implementation track. This PR only aligns existing settings with the current Compact Worklog default model.Verification
node --check static/boot.js static/panels.js static/ui.js static/i18n.jspython3 -m py_compile api/config.py tests/test_1003_preferences_autosave.py tests/test_issue3595_activity_default_expanded.py tests/test_simplified_tool_calling_setting.py tests/test_ui_tool_call_cleanup.pypytest tests/test_ui_tool_call_cleanup.py tests/test_issue3595_activity_default_expanded.py tests/test_simplified_tool_calling_setting.py tests/test_1003_preferences_autosave.py tests/test_issue1824_cli_patch_diff_rendering.pypytest tests/ -v --timeout=60 --shard-id=0 --num-shards=3git diff --checkpython3 scripts/scope_undef_gate.pyattempted locally, skipped becauseeslintis not installed on PATH; GitHub CIlintpassed the scope/undefined-reference gate