feat(config): migrate all remaining writers to patch transactions - #1513
feat(config): migrate all remaining writers to patch transactions#1513cyhhao wants to merge 27 commits into
Conversation
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: faf54e4731
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Both P1s fixed in 9dc9518: P1 stale-decision application: P1 full-snapshot UI callers: 602 backend tests + ruff green. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9dc9518e5e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
P1 agent-section snapshots — fixed in this head: |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d943ad1e9b
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…inside the transaction
|
Both round-4 P1s fixed in 1b65630: P1 ChannelList snapshot: P1 WeChat QR section staleness: 190 + 122 tests, ruff, UI build + lint all green. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1b656307d1
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Round-5 P1 (stale enabled-list replacement) fixed in 8c054de with a list-operations verb instead of another caller patch:
191 + 117 tests, ruff, UI build + lint green. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8c054dea4b
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Round-6 findings addressed in dd17780 — all three concern the NEW list-ops verb (same-shape per the standing rule), not new snapshot sites: P1 validation bypass: after the list ops apply, the payload now surfaces the FINAL post-operation P1 reconciliation skip: P2 ASGI loop blocking: 308 + 71 tests, ruff green. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: dd1778035f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Fixed in 0b6f8ea: the credential-apply save now sends ONLY the card's |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0b6f8eaef0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Round-8 disposition — circuit breaker engaged for the snapshot class: P1 list-ops whitelist — fixed in d109426 (same-shape on the new verb): P1 setup-wizard snapshots — deferred, not patched here. This is the seventh consecutive single-site full-snapshot finding (platforms page → backends page → runtime hook → channels → WeChat QR → credential-apply → wizard). Per the review-loop circuit breaker we stop reviewer-driven whack-a-mole: the systematic sweep is tracked as #1517 (grep every The wizard thread is intentionally left unresolved pending the owner's merge decision (waive-and-defer-to-#1517 vs fix-here). |
|
Setup-wizard P1 fixed in be52217 (owner-directed continuation) — both wizard save paths narrowed to wizard-owned fields:
UI build + lint green; backend suites green (179 tests). |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: be5221717e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Fixed in c0b8ce8: |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c0b8ce8a05
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Fixed in 9f03e0f: the Platform Selection step now diffs its credential draft against a mount-time snapshot ( |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9f03e0f53a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 3b32948f50
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5ad5e74811
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4fe44ad03b
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 09c77e2f0b
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7fe3dd90f2
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: b388448cf5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
@codex review |
|
Codex Review: Didn't find any major issues. Keep it up! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Summary
This PR completes stage 3 of the config write-serialization plan. The core
direction is to make the mutation owner explicit at both boundaries:
ApiContext.mutateConfigis the only UI path thatposts to
/api/config. Callers submit field-level mutations or explicitplatform list operations; Wizard and Messaging flows no longer resubmit
mount-time or remote full-config snapshots.
config_file_lockis the singlecross-process lock for a complete lock-fresh read/merge/validate/write cycle.
Existing patch mutators and first-run/QR writers use that boundary, and the
remaining endpoint preserves its merge-patch API compatibility.
The lock serializes overlapping writers, but it cannot make a stale snapshot
safe. That is why the explicit UI mutation protocol and the server-side
lock-fresh mutators are both required.
What changed
mutateConfigand centralized payloadserialization, including Wizard, Settings Messaging, platform/backend
settings, runtime settings, channels, and workbench controls.
platforms.enabledand validation thatrejects unsafe, undefined, conflicting, or object-valued leaf mutations.
owns; finish persistence submits setup/auto-update changes and list ops only.
config_file_lock, removing the duplicatelock abstraction and narrowing the WeChat QR writer to its token plus an
explicit platform enable operation.
/api/configmutation boundary,plus focused unit, transaction, auth, runtime, and UI regression coverage.
masterinto the branch without rewriting history.Validation
tests, and 361 runtime/UI-server/CLI/WeChat tests passed locally.
(only existing dependency/chunk-size warnings remain).
git diff --checkpassed.Review close criteria
The PR is ready to merge only after the pushed head has green CI and no
unresolved actionable review threads. The tracker issue remains open until
that condition is met; no merge is performed by this change.
Dependencies
None.