refactor(settings): centralize Settings Snapshot Publication - #352
Merged
Merged
Conversation
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
Menu edits and file reloads previously published Settings Snapshots through different sequences. Overlay and Vocabulary callbacks could still run after allocation prevented publication.
Introduce Settings Snapshot Publication as the shared owner of typed edits, retained values, change detection, publication, daemon effects, and persistence. Preparation failures change nothing; failed saves leave the accepted change live. Invalid reloads keep live settings, valid reloads remain authoritative, and an existing unpatchable file is preserved. Same-value Save retries persistence without dispatching effects.
The menu now reports explicit edit failures, and radio choices are tested through publication, disk, and read-back. The agreed design is documented in
docs/settings-publication.md; this completes the settings write work deferred by ADR-0011.Type of change
Checklist
zig build --summary allpasses in the pinned development environment, including the test gate: 678 Zig tests, 34 Python tests, and strict mypy checksAppKit alerts compile in the production executable but have not been exercised interactively.