Skip to content

refactor(ui): derive Settings view props from the page owner - #177724

Merged
steipete merged 2 commits into
mainfrom
solid2/w-config-owner-props
Oct 19, 2026
Merged

steipete merged 2 commits into
mainfrom
solid2/w-config-owner-props

Conversation

@steipete

@steipete steipete commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Settings keeps a second manually maintained copy of the data and callbacks its page owner already provides.

User Impact

No user-visible change. Settings keeps its existing behavior, routes, selectors, and lazy loading.

Why This Change Was Made

Derive the rendering contract from the existing page owner, keep presentation-state types with their state helpers, and call the existing settings update function directly. Seven single-caller section, locale, and theme helpers now live in their existing callback slots, removing forwarding layers without changing their operations. Renderer-specific options retain their existing contracts, including optional file/notification capabilities and standalone notification actions. All 60 previously optional renderer fields remain optional; the original shared fixture typechecks without changes.

The branch is reconciled with #177624: schema analysis stays in the view memo and the page reuses the stable section arrays from main. The owner gains explicit callback argument types previously provided by the duplicated interface. No runtime imports or dependencies were added.

Evidence

Proof Result
UI typecheck Passed (pnpm tsgo:ui, tsrs)
UI-pages test typecheck Passed (test/tsconfig/tsconfig.core.test.ui-pages.json, tsrs)
Config raw, main-view, and appearance browser tests 3 files, 47 tests passed on the original patch; pinned Bun, one worker, run once. Conflict resolution is covered by post-merge types and unchanged-runtime comparison; full PR CI covers the merged head
Static import cycle check 0 cycles
Solid controller/reactivity guard Passed; ratchets unchanged
Scoped lint and formatting Passed for all four changed files (tsconfig.ui.json)
Optional renderer contract All 60 optional field names preserved; original fixture typechecks unchanged
Runtime emission comparison All four production files match the base after mechanically accounting for the direct settings callback and inlined single-caller handlers
Independent review Final review clean (no actionable P0–P2 findings); optional-capability finding fixed and all 60 optional fields preserved. Subsequent type-only import compaction typechecked
Production Knip Run; outside-diff findings recorded below

Knip reported collectEntriesForBranchSummaryFromBranches, generateBranchSummary, TreePreparation, and PackageSource/WarningSettings in the agent runtime/session owners. Those files are unchanged by this PR and match origin/main at 0548086d6a95525d7bad7f1905d2ae8c8d2de3ef; matching main-run evidence is still pending, so these are not claimed as proven inherited. Its newly unused WebPushSnapshot finding was addressed by consuming the canonical snapshot type for the optional renderer field. No ignores were added.

No markup or CSS changed. Build and screenshot capture were omitted under the lane's bounded proof rules. ci:full requests the broad UI proof.

LOC Before After Delta
Production 1,529 1,432 −97
Test changes 0 0 0
Total touched files 1,529 1,432 −97

Counts cover the four touched files against merge base 34f6f1ba01cec96639031a47e736849b14bc072a. Solid checklist: effects 1 → 1; controllers, render effects, untrack, direct listeners, DOM queries, flush, and owner APIs all 0 → 0. No touched file has an entry in config/max-lines-baseline.txt; the pre-commit line-cap ratchet passes with the oversized page owner seven raw lines smaller with no counted-line growth.

Completed CI and inherited failure evidence

Exact-head run 39324369438 completed with all selected runtime groups passing, including UI units, full Control UI E2E, real-Gateway, performance, and security-fast. The only failed jobs were check-test-types-core-4, check-lint-core-1, and their aggregate gate.

The two static jobs fail in src/gateway/local-http-probe.test.ts: TS2304 for the missing createDeferredCore import at 154, TS7006 for the rejection parameter at 178, and the corresponding prefer-promise-reject-errors diagnostic. The actual tested merge a41da1c44dfbf5b2f1072e2507c5ea2f95adb2c9 has ordered parents 42e05fbbb12e99b534c3fb4babe173b4ad7ee361 (main) and this PR head. Its failing test blob is identical to the baseline; the same named diagnostics reproduce on main commit 2cc639d702348bb802671e1d8f2791b65ab4ba0f. Main repair 08e32fdb4df002c9d4eea158b855d6521dd1e916 restores the missing import. Native inherited-failure admission uses these exact-source and baseline reproduction artifacts; failed CI is not relabeled as green.

@steipete steipete added the ci:full Keep ordinary native-locale CI selection on the next PR run. label Oct 19, 2026
@clawsweeper

clawsweeper Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-19T21:07:08.378354Z 1342d4a New commits
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Oct 19, 2026
@clawsweeper

clawsweeper Bot commented Oct 19, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

This PR derives Settings renderer props from the existing page owner, relocates presentation types, and removes single-caller forwarding helpers.

Example: In Settings → Appearance, select the system theme mode.

  • Before: The renderer forwards the selection through a separate helper to the existing preference owner.
  • After: The callback performs the same preference operation directly, preserving the displayed result and reset behavior.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) The patch is focused and source-consistent, with supporting browser-test and typecheck evidence but no shipped-entry-point demonstration.
Proof confidence 🦐 gold shrimp (3/6) This maintainer-authored refactor is outside the ordinary contributor proof gate; its supplied evidence covers browser tests, typechecks, and emission comparison rather than a demonstrated shipped Settings session.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Refactor · Worth it: Yes · Fix scope: Complete
User problem: No current user-visible failure is claimed; duplicated Settings contracts create maintenance drift risk.
Reason: The maintainer-authored direction removes redundant definitions and forwarding layers while preserving existing renderer capabilities and behavior.

Merge readiness

✅ Ready for maintainer review

Keep this PR open: it is a useful maintainer-authored simplification, and the reviewed diff introduces no concrete correctness or security finding.

Priority: P3
Reviewed head: 1342d4a3dc3aa728cd8d0594bed19d86cc23bd59

Before merge

None.

Findings

None.

Tests

  • Missing end-to-end proof: The supplied evidence contains no shipped-browser run exercising the refactored Settings callbacks.
Agent review details

How this fits together

The Settings page owner reads configuration and preference owners, supplies data and callbacks to Solid renderers, and delegates writes to the existing runtime and preference operations.

flowchart LR
  A[Configuration and preference owners] --> B[Settings page owner]
  B --> C[Derived renderer contract]
  C --> D[Settings renderer]
  D --> E[Existing mutation callbacks]
  E --> A
Loading

Technical review

Best possible solution:

Retain the derived page-owner contract and explicit renderer options while preserving the existing preference and configuration write owners.

Do we have a high-confidence way to reproduce the issue?

This is a behavior-preserving refactor rather than a reported runtime bug; source inspection confirms the duplicated contract and forwarding helpers.

Is this the best way to solve the issue?

The change uses the existing page owner as the contract source, retains legitimate renderer differences, and removes the replaced forwarding paths without adding another owner.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 54528302f13b.

Provenance checked

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

PR surface

Source -97. Total -97 across 4 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 4 203 300 -97
Tests 0 0 0 0
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 4 203 300 -97

Review metrics

Metric Value Why it matters
Production versus test LOC Production +203/−300; tests +0/−0 The net reduction removes duplicated contracts and forwarding helpers without adding runtime machinery or test scaffolding.

Labels

Label changes:

  • add P3: This is internal Settings contract cleanup with no intended user-visible behavior change.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Label justifications:

  • P3: This is internal Settings contract cleanup with no intended user-visible behavior change.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed October 19, 2026, 5:18 PM ET / 21:18 UTC.

@steipete
steipete enabled auto-merge (squash) October 19, 2026 21:23
@steipete
steipete disabled auto-merge October 19, 2026 21:45
@steipete
steipete merged commit 63efef4 into main Oct 19, 2026
107 of 111 checks passed
@steipete
steipete deleted the solid2/w-config-owner-props branch October 19, 2026 22:17
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via explicitly authorized admin squash with attributed pre-existing CI failures.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui ci:full Keep ordinary native-locale CI selection on the next PR run. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. size: L status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant