Repository navigation
refactor: reuse channel setup config writers - #143547
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review in progressClawSweeper is reviewing this revision. This supersedes any previous blocked status. |
|
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Codex review: needs maintainer review before merge. Reviewed September 9, 2026, 9:42 PM ET / September 10, 2026, 01:42 UTC. ClawSweeper reviewWhat this changesThe PR replaces repeated channel configuration updates with existing SDK writers while preserving plugin-specific setup, account promotion, removal, and disabling behavior. Merge readiness✅ Ready for maintainer review Keep open: this maintainer-requested cleanup remains distinct from current main, and source inspection found no actionable regression. Priority: P3 Review scores
Verification
How this fits togetherChannel setup adapters turn operator input and existing configuration into updated channel settings. Shared SDK writers copy the configuration sections while each plugin retains its account and credential policy. flowchart LR
A[Operator setup input] --> C[Plugin setup adapter]
B[Existing channel settings] --> C
C --> D[Plugin account policy]
D --> E[Shared configuration writer]
E --> F[Updated channel settings]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource -59, Other 0. Total -59 across 12 files. View PR surface stats
Review metricsNone. Technical reviewBest possible solution: Use the existing section writers while retaining account selection, field deletion, cloning, and credential decisions in their plugin owners. Do we have a high-confidence way to reproduce the issue? Not applicable: this PR proposes behavior-preserving cleanup rather than a reported defect; source comparison found no introduced failure. Is this the best way to solve the issue? Yes: the existing SDK writers express the same operations without adding APIs or relocating plugin-specific policy. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against c98e00b4f94f. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
What Problem This Solves
Channel setup and account changes repeat the same root/channel object-copying logic across eight plugins. This maintainer-requested cleanup gives those writes one existing owner while preserving each plugin's account and migration policy.
Why This Change Was Made
Use the existing setup SDK writers for 12 equivalent section updates across A2A, Feishu, Matrix, Microsoft Teams, Reef, Signal, Slack, and WhatsApp. Keep account selection, default-account promotion, field deletion, cloning, and credential decisions with their current plugin owners. Remove ten unnecessary type assertions and shrink their four existing baseline entries.
User Impact
No intended behavior change. Setup, disabling a channel, account removal, and account promotion retain their existing config values, unknown fields, missing-versus-undefined properties, raw account keys, and unchanged-reference outcomes. The change removes 58 production code lines without new helpers or SDK exports.
Evidence