Layout Engine refactor: A/C phase separation + cache key stabilization - #1486
Layout Engine refactor: A/C phase separation + cache key stabilization#1486Yuxin-Qiao wants to merge 1 commit into
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed June 13, 2026, 10:36 AM ET / 14:36 UTC. Summary Reproducibility: yes. from source inspection: a submenu row through Review metrics: 2 noteworthy metrics.
Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Mantis proof suggestion Risk before merge
Maintainer options:
Next step before merge
Security Review findings
Review detailsBest possible solution: Preserve the C/A split only after restoring detach-before-attach submenu ownership and adding redacted real CodexBar menu proof for provider switching, submenu rows, and stable card heights. Do we have a high-confidence way to reproduce the issue? Yes from source inspection: a submenu row through Is this the best way to solve the issue? No: the phase split may be maintainable, but it must keep current main's detach-before-assign submenu invariant and provide real app proof before merge. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 88d6360811df. Label changesLabel justifications:
Evidence reviewedWhat I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d3470fb3a1
ℹ️ 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".
| let view = newItem.view | ||
| newItem.view = nil | ||
| let submenu = newItem.submenu | ||
| liveItem.submenu = newItem.submenu |
There was a problem hiding this comment.
Detach submenus before moving them between items
When cached merged-menu content is swapped and a live row owns a submenu (for example the usage/credits/history menu-card rows), swapMenuItemContents calls applyMenuItemContent(holder, from: liveItem), so this assignment tries to attach liveItem.submenu to holder while that submenu still has the live menu as its supermenu. AppKit rejects submenus that already have a supermenu, which can crash the tab switch path; keep the old order by saving the submenu, clearing newItem.submenu, and only then assigning it to liveItem.
Useful? React with 👍 / 👎.
d3470fb to
d8eb67a
Compare
|
This PR is a deterministic architecture refactor, not a UI behavior change. Clarifications for review:
Conclusion: |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Thanks for working on the menu pipeline. I rebased and reviewed this against current Both ClawSweeper and a separate local autoreview found the same blocker: The claimed three-way content/view rotation is already implemented by Closing rather than landing additional live-menu risk. A narrower follow-up is welcome if it demonstrates a concrete behavior or performance change with focused regression coverage and runtime menu proof. |
Summary
Layout Engine refactor separating menu rendering into a strict two-phase pipeline.
Changes (5 files)
updateMenuItemInPlaceintoapplyMenuItemContent(C-phase) + view-onlyupdateMenuItemInPlace(A-phase)swapMenuItemContentsfor both content and viewsTest Results