Complete editor memory, large-paste and scrolling performance verification #13

Open
opened 2026-09-13 13:34:43 +00:00 by kayg · 13 comments
Owner

Request and current status

Bounded Select All and parsing improvements were measured historically. No general leak or current strict launch/key-repeat acceptance.

Acceptance

Profile current Release through actual drawing with revision/hardware/corpus/boundaries/artifacts. Repeat large paste, selection and scroll with mixed blocks/images. Compare Mailternal startup and obtain performance review. Do not substitute unit timing/screenshots.

Keep open until the user-facing outcome is verified in a delivered build. Source review or a successful build alone is not completion.

## Request and current status Bounded Select All and parsing improvements were measured historically. No general leak or current strict launch/key-repeat acceptance. ## Acceptance Profile current Release through actual drawing with revision/hardware/corpus/boundaries/artifacts. Repeat large paste, selection and scroll with mixed blocks/images. Compare Mailternal startup and obtain performance review. Do not substitute unit timing/screenshots. Keep open until the user-facing outcome is verified in a delivered build. Source review or a successful build alone is not completion.
Author
Owner

Worker/role: /root/sidebar_live_geometry_diagnosis, now owning bounded performance diagnosis for issue #13. No source ownership or edits are planned in this phase.

Current candidate boundary: integrated Release revision 6ca85fd2d82428d4fe18db508535bc643f3a0ee4. Baseline boundary: retained signed Release 153d7c1fd7a8a9f8d3e25df2b6f6dcb87e13dddf. The current candidate's executable hash and immutable VM path will be read from build/provenance receipts before capture; no unstamped or Debug artifact will be accepted.

Plan:

  1. Reuse .agents/editor-overnight-performance-protocol.md and the frozen harness snapshot from 63188563998dc1d0aa640712fd338c4ea32d7be5; verify all manifest, collector, parser, executable, signature, revision, hardware and corpus receipts before launch.
  2. Coordinate with root for an exclusive VM lease and compiler/build-lane idle state. Use only lume@calternal-macos-vm, never the user's desktop or real vault.
  3. Restore and byte-verify the canonical 10,000-line note in the isolated 1,200-day indexed Space. Capture separate fresh Release processes for large full-selection paste, Select All, and bounded native Page Down scrolling. Each workload retains before/after source hashes, point-in-time RSS, /usr/bin/sample profiles spanning input, AppTrace actual-draw boundaries where available, and exact native input receipts.
  4. Treat selection and editor scrolling as CPU/memory diagnostics because the existing trace schema does not expose selection-to-draw or editor-scroll frame delivery. Do not manufacture latency or leak thresholds. Repeated fresh/matched cycles may establish plateau behavior; /usr/bin/sample and RSS alone cannot prove absence of leaks.
  5. Run the frozen strict sidebar smoke only after the VM state receipt is valid. If smoke passes, schedule balanced A/B/B/A/A/B baseline/candidate runs without changing parser thresholds. Compare Mailternal launch only through an equivalently stamped Release/content-draw boundary; otherwise record that acceptance item as still open.
  6. Add a separate mixed-list/image workload after the canonical no-image controls, preserving exact fixture and asset hashes. Keep its evidence separate from the canonical workload.
  7. Obtain independent performance review before any acceptance claim.

Immediate next action: audit the retained 6ca85 Release provenance and current harness/result inventory while waiting for root's VM lease. Issue remains open.

Worker/role: `/root/sidebar_live_geometry_diagnosis`, now owning bounded performance diagnosis for issue #13. No source ownership or edits are planned in this phase. Current candidate boundary: integrated Release revision `6ca85fd2d82428d4fe18db508535bc643f3a0ee4`. Baseline boundary: retained signed Release `153d7c1fd7a8a9f8d3e25df2b6f6dcb87e13dddf`. The current candidate's executable hash and immutable VM path will be read from build/provenance receipts before capture; no unstamped or Debug artifact will be accepted. Plan: 1. Reuse `.agents/editor-overnight-performance-protocol.md` and the frozen harness snapshot from `63188563998dc1d0aa640712fd338c4ea32d7be5`; verify all manifest, collector, parser, executable, signature, revision, hardware and corpus receipts before launch. 2. Coordinate with root for an exclusive VM lease and compiler/build-lane idle state. Use only `lume@calternal-macos-vm`, never the user's desktop or real vault. 3. Restore and byte-verify the canonical 10,000-line note in the isolated 1,200-day indexed Space. Capture separate fresh Release processes for large full-selection paste, Select All, and bounded native Page Down scrolling. Each workload retains before/after source hashes, point-in-time RSS, `/usr/bin/sample` profiles spanning input, AppTrace actual-draw boundaries where available, and exact native input receipts. 4. Treat selection and editor scrolling as CPU/memory diagnostics because the existing trace schema does not expose selection-to-draw or editor-scroll frame delivery. Do not manufacture latency or leak thresholds. Repeated fresh/matched cycles may establish plateau behavior; `/usr/bin/sample` and RSS alone cannot prove absence of leaks. 5. Run the frozen strict sidebar smoke only after the VM state receipt is valid. If smoke passes, schedule balanced A/B/B/A/A/B baseline/candidate runs without changing parser thresholds. Compare Mailternal launch only through an equivalently stamped Release/content-draw boundary; otherwise record that acceptance item as still open. 6. Add a separate mixed-list/image workload after the canonical no-image controls, preserving exact fixture and asset hashes. Keep its evidence separate from the canonical workload. 7. Obtain independent performance review before any acceptance claim. Immediate next action: audit the retained `6ca85` Release provenance and current harness/result inventory while waiting for root's VM lease. Issue remains open.
Author
Owner

Worker: /root/sidebar_live_geometry_diagnosis (performance diagnosis), VM lease released after this comment.

Completed one bounded, current-candidate Release paste profile. This is evidence for issue scoping, not performance acceptance.

Boundary and environment:

  • candidate source 6ca85fd2d82428d4fe18db508535bc643f3a0ee4, source tree 740c18c0a151887bf9fd6cfcda5d950b9922639b
  • staged executable SHA-256 606412e94003538797fdfdc625aa9ded3e8267c8d7ecc929950b519cc62ce5d2, strict signature verification passed, ARM64 Release
  • VM calternal-macos-vm.local, macOS 26.6.2 (25G83), exact 960×637 window at (0,30)
  • 1,200-day synthetic Space 6fb1e0c3-7cd4-4088-9034-f35d90bbb870; canonical no-image fixture 178,012 bytes, SHA-256 865dfd01e37dbdf33e1e5562e609c25ce8772f780ae0274b88b35ae40ca89342
  • rendered System 15 pt, line spacing 4 pt, paragraph spacing 8 pt; source note visibly open and body visibly selected before the sample
  • clipboard readback exactly 177,779 UTF-8 bytes, SHA-256 11d4a13fb74de6d52709948fe005c3effe017fb7609a134f576542365609b149, no final newline
  • one fresh process, one native Cmd-V, 30-second /usr/bin/sample begun two seconds before paste; AppTrace logger began before launch

Result:

  • native hotkey RPC returned in 1.102 s; the post-super TextKit draw marker reports rendered-editor-edit-draw 820,794,250 ns, generation 1, zero coalesced edits
  • on-disk postimage was exactly the retained frontmatter plus the expected payload: 177,976 bytes, expected SHA-256 ae04380a9607555b61d50bc82c9ef10b041dcca9b58d2324b4f8ed880ec088cc
  • RSS was 204,096 KiB before, 229,504 KiB after (+25,408 KiB), and 231,936 KiB after Undo/recovery (+27,840 KiB from pre-paste). One run cannot distinguish cache retention from a leak.
  • the 30-second profile captured 435 samples in BlockEditorView.paste, 384 in the editor delegate, and 286 in applyDisplayReplacement; the dominant mutation subtree was MarkdownBlockDocument.applyingSourceRange/synchronizeEditedRegion, including 109 samples in block parsing and 115 in incremental projection rebuild. A later deferred caret reveal contributed 55 samples, including 33 in TextKit viewport relocation. The process was idle for 19,341 of 19,842 main-thread samples, so the captured active burst is bounded rather than a whole-run CPU average.
  • one native Cmd-Z restored the exact body and all metadata except the expected automatic last edited timestamp. The app then quit normally; the fixture was replaced only after quit and verified back to canonical SHA-256. The exact app PID and owned AppTrace logger were absent at cleanup.

Artifacts: /Users/lume/Performance/results/6ca85fd2-paste-issue13-02/ on the QA VM, with a 59-file SHA-256 manifest, raw AppTrace NDJSON, full sample, memory snapshots, exact source before/after/Undo files, clipboard receipt, native-action receipts, screenshots used only for state identity, and cleanup receipts. Invalid setup attempt .../6ca85fd2-paste-issue13-01/ is explicitly marked INVALID: an untargeted deep link launched a second installed process; it made no mutation and was excluded.

Limits and next action: baseline 153d7c1fd7a8a9f8d3e25df2b6f6dcb87e13dddf was not run in this short lease, so no A/B claim is made. Select-All, Page Down, mixed-image workload, strict sidebar key-repeat, repeated memory cells, Mailternal comparison, and independent performance review remain open. The compiler hold is released now so the user preview build can proceed; resume with separate fresh processes and the same exact boundaries.

Worker: `/root/sidebar_live_geometry_diagnosis` (performance diagnosis), VM lease released after this comment. Completed one bounded, current-candidate **Release** paste profile. This is evidence for issue scoping, not performance acceptance. Boundary and environment: - candidate source `6ca85fd2d82428d4fe18db508535bc643f3a0ee4`, source tree `740c18c0a151887bf9fd6cfcda5d950b9922639b` - staged executable SHA-256 `606412e94003538797fdfdc625aa9ded3e8267c8d7ecc929950b519cc62ce5d2`, strict signature verification passed, ARM64 Release - VM `calternal-macos-vm.local`, macOS 26.6.2 (25G83), exact 960×637 window at (0,30) - 1,200-day synthetic Space `6fb1e0c3-7cd4-4088-9034-f35d90bbb870`; canonical no-image fixture 178,012 bytes, SHA-256 `865dfd01e37dbdf33e1e5562e609c25ce8772f780ae0274b88b35ae40ca89342` - rendered System 15 pt, line spacing 4 pt, paragraph spacing 8 pt; source note visibly open and body visibly selected before the sample - clipboard readback exactly 177,779 UTF-8 bytes, SHA-256 `11d4a13fb74de6d52709948fe005c3effe017fb7609a134f576542365609b149`, no final newline - one fresh process, one native Cmd-V, 30-second `/usr/bin/sample` begun two seconds before paste; AppTrace logger began before launch Result: - native hotkey RPC returned in 1.102 s; the post-super TextKit draw marker reports `rendered-editor-edit-draw` **820,794,250 ns**, generation 1, zero coalesced edits - on-disk postimage was exactly the retained frontmatter plus the expected payload: 177,976 bytes, expected SHA-256 `ae04380a9607555b61d50bc82c9ef10b041dcca9b58d2324b4f8ed880ec088cc` - RSS was 204,096 KiB before, 229,504 KiB after (+25,408 KiB), and 231,936 KiB after Undo/recovery (+27,840 KiB from pre-paste). One run cannot distinguish cache retention from a leak. - the 30-second profile captured 435 samples in `BlockEditorView.paste`, 384 in the editor delegate, and 286 in `applyDisplayReplacement`; the dominant mutation subtree was `MarkdownBlockDocument.applyingSourceRange`/`synchronizeEditedRegion`, including 109 samples in block parsing and 115 in incremental projection rebuild. A later deferred caret reveal contributed 55 samples, including 33 in TextKit viewport relocation. The process was idle for 19,341 of 19,842 main-thread samples, so the captured active burst is bounded rather than a whole-run CPU average. - one native Cmd-Z restored the exact body and all metadata except the expected automatic `last edited` timestamp. The app then quit normally; the fixture was replaced only after quit and verified back to canonical SHA-256. The exact app PID and owned AppTrace logger were absent at cleanup. Artifacts: `/Users/lume/Performance/results/6ca85fd2-paste-issue13-02/` on the QA VM, with a 59-file SHA-256 manifest, raw AppTrace NDJSON, full sample, memory snapshots, exact source before/after/Undo files, clipboard receipt, native-action receipts, screenshots used only for state identity, and cleanup receipts. Invalid setup attempt `.../6ca85fd2-paste-issue13-01/` is explicitly marked `INVALID`: an untargeted deep link launched a second installed process; it made no mutation and was excluded. Limits and next action: baseline `153d7c1fd7a8a9f8d3e25df2b6f6dcb87e13dddf` was not run in this short lease, so no A/B claim is made. Select-All, Page Down, mixed-image workload, strict sidebar key-repeat, repeated memory cells, Mailternal comparison, and independent performance review remain open. The compiler hold is released now so the user preview build can proceed; resume with separate fresh processes and the same exact boundaries.
Author
Owner

Worker: /root/sidebar_live_geometry_diagnosis (bounded performance follow-up).

Isolated worktree: /Users/kayg/Developer/calternal-app/.worktrees/editor-caret-relocation-perf

Branch: wave16/editor-caret-relocation-perf

Base: exact integration 37c5d40de40a2d0b279aad8d13d6f68837533c2d (Extend note background through top safe area), clean at creation.

Current state: planning only; no source edits, build, compiler lease, or VM use. The retained 6ca85 Release profile measured 820,794,250 ns from accepted paste mutation to post-super editor draw. Its 30-second sample localized the synchronous mutation to parse/projection work and separately caught the deferred caret-reveal closure spending 55 samples, including 33 in TextKit viewport relocation.

Immediate next action: reread the editor architecture and viewport/caret invariants at this exact base, propose the smallest reversible change that can be measured A/B against the existing paste protocol, and obtain independent reviewer feedback before implementation. The plan will preserve source mapping, caret visibility, EOF behavior, undo ownership, and the current viewport-recovery fixes. Issue stays open.

Worker: `/root/sidebar_live_geometry_diagnosis` (bounded performance follow-up). Isolated worktree: `/Users/kayg/Developer/calternal-app/.worktrees/editor-caret-relocation-perf` Branch: `wave16/editor-caret-relocation-perf` Base: exact integration `37c5d40de40a2d0b279aad8d13d6f68837533c2d` (`Extend note background through top safe area`), clean at creation. Current state: planning only; no source edits, build, compiler lease, or VM use. The retained `6ca85` Release profile measured 820,794,250 ns from accepted paste mutation to post-super editor draw. Its 30-second sample localized the synchronous mutation to parse/projection work and separately caught the deferred caret-reveal closure spending 55 samples, including 33 in TextKit viewport relocation. Immediate next action: reread the editor architecture and viewport/caret invariants at this exact base, propose the smallest reversible change that can be measured A/B against the existing paste protocol, and obtain independent reviewer feedback before implementation. The plan will preserve source mapping, caret visibility, EOF behavior, undo ownership, and the current viewport-recovery fixes. Issue stays open.
Author
Owner

Bounded source plan from the retained current-Release trace (planning only; issue remains open).

The 6ca85fd2 native large-paste sample contains three distinct reveal workloads for one accepted replacement:

  • applyDisplayReplacement -> revealAndScheduleScroll: 96 samples, including 89 in TextKit viewport relocation;
  • AppKit _readSelectionFromPasteboard -> this view's scrollRangeToVisible: another 39 samples, split between layout and relocation;
  • the scheduled reconciliation closure: 55 samples, including 33 in viewport relocation and 22 in viewport layout.

The 55-sample closure root can aggregate more than one invocation, so the trace does not justify claiming all 190 sampled milliseconds are removable. It does prove that the same native paste transaction requests an immediate reveal through the canonical replacement seam and then asks the editor to reveal again through AppKit. Source synchronization, parsing, and projection rebuilding remain the larger synchronous cost.

Proposed first candidate, on isolated branch wave16/editor-caret-relocation-perf at exact base 37c5d40de40a2d0b279aad8d13d6f68837533c2d:

  1. Add one private, short-lived pending-reveal value to BlockEditorView, keyed by source revision, requested display range, selected range, and reveal mode.
  2. In the non-local branch of revealAndScheduleScroll, suppress only an exact duplicate request that arrives before the already scheduled reconciliation runs.
  3. Record the pending value only after the first immediate revealInsertionPoint succeeds. If TextKit cannot reveal, leave no token so AppKit's later request remains a recovery attempt.
  4. The scheduled closure consumes its own exact token before rechecking the existing revision, selection, attachment, editability, and layout fences. A newer or different request supersedes the old closure. No pasteboard-specific behavior or canonical document code changes.

This preserves one immediate TextKit relocation and one deferred post-layout reconciliation, which prior caret fixes established as necessary for distant and EOF positions. It also avoids relying on undocumented paste callback ordering: any exact same-turn duplicate can coalesce, while a different range, revision, selection, or later-turn request still executes.

Risks to review before implementation:

  • AppKit may deliberately repeat an exact same-turn request after the first reveal only partially succeeds. The retained deferred reconciliation is intended to cover that case, but runtime caret proof is required.
  • General same-turn coalescing also covers Find, Accessibility, block selection, and Undo calls routed through this method. The exact key and one-main-turn lifetime must prevent suppression after any state change.
  • If AppKit's post-paste range differs from the canonical result, this candidate safely does nothing and may produce no measurable gain.
  • The candidate does not optimize Markdown parsing or projection. Changing the disposable projection transaction before a clean A/B would put source mapping, stable block IDs, native Undo, IME, and VoiceOver at unnecessary risk.

Planned A/B after review and build-owner handoff: exact 37c5d40 baseline versus candidate Release, same VM/hardware, restored 1,200-day corpus, canonical 10k selection, exact 177,779-byte payload, fresh process and actual content draw. Compare accepted-edit-to-draw, hotkey return, reveal/relocation sample subtrees, exact postimage, Undo source recovery, RSS, and repeat enough matched cells to distinguish noise. Then exercise distant navigation, EOF paste/typing, native selection, and mixed blocks/images. This bounded cell is only one part of issue #13's broader launch, key-repeat, mixed-image, leak, and Mailternal acceptance.

Bounded source plan from the retained current-Release trace (planning only; issue remains open). The `6ca85fd2` native large-paste sample contains three distinct reveal workloads for one accepted replacement: - `applyDisplayReplacement` -> `revealAndScheduleScroll`: 96 samples, including 89 in TextKit viewport relocation; - AppKit `_readSelectionFromPasteboard` -> this view's `scrollRangeToVisible`: another 39 samples, split between layout and relocation; - the scheduled reconciliation closure: 55 samples, including 33 in viewport relocation and 22 in viewport layout. The 55-sample closure root can aggregate more than one invocation, so the trace does not justify claiming all 190 sampled milliseconds are removable. It does prove that the same native paste transaction requests an immediate reveal through the canonical replacement seam and then asks the editor to reveal again through AppKit. Source synchronization, parsing, and projection rebuilding remain the larger synchronous cost. Proposed first candidate, on isolated branch `wave16/editor-caret-relocation-perf` at exact base `37c5d40de40a2d0b279aad8d13d6f68837533c2d`: 1. Add one private, short-lived pending-reveal value to `BlockEditorView`, keyed by source revision, requested display range, selected range, and reveal mode. 2. In the non-local branch of `revealAndScheduleScroll`, suppress only an exact duplicate request that arrives before the already scheduled reconciliation runs. 3. Record the pending value only after the first immediate `revealInsertionPoint` succeeds. If TextKit cannot reveal, leave no token so AppKit's later request remains a recovery attempt. 4. The scheduled closure consumes its own exact token before rechecking the existing revision, selection, attachment, editability, and layout fences. A newer or different request supersedes the old closure. No pasteboard-specific behavior or canonical document code changes. This preserves one immediate TextKit relocation and one deferred post-layout reconciliation, which prior caret fixes established as necessary for distant and EOF positions. It also avoids relying on undocumented paste callback ordering: any exact same-turn duplicate can coalesce, while a different range, revision, selection, or later-turn request still executes. Risks to review before implementation: - AppKit may deliberately repeat an exact same-turn request after the first reveal only partially succeeds. The retained deferred reconciliation is intended to cover that case, but runtime caret proof is required. - General same-turn coalescing also covers Find, Accessibility, block selection, and Undo calls routed through this method. The exact key and one-main-turn lifetime must prevent suppression after any state change. - If AppKit's post-paste range differs from the canonical result, this candidate safely does nothing and may produce no measurable gain. - The candidate does not optimize Markdown parsing or projection. Changing the disposable projection transaction before a clean A/B would put source mapping, stable block IDs, native Undo, IME, and VoiceOver at unnecessary risk. Planned A/B after review and build-owner handoff: exact `37c5d40` baseline versus candidate Release, same VM/hardware, restored 1,200-day corpus, canonical 10k selection, exact 177,779-byte payload, fresh process and actual content draw. Compare accepted-edit-to-draw, hotkey return, reveal/relocation sample subtrees, exact postimage, Undo source recovery, RSS, and repeat enough matched cells to distinguish noise. Then exercise distant navigation, EOF paste/typing, native selection, and mixed blocks/images. This bounded cell is only one part of issue #13's broader launch, key-repeat, mixed-image, leak, and Mailternal acceptance.
Author
Owner

Reviewer outcome on the first plan: changes required before implementation. The retained trace proves a repeated reveal inside native super.paste, but it does not justify changing same-turn behavior for Find, Accessibility, Undo, navigation, or structural commands. The reviewer also identified two lifecycle requirements: fence the deferred work to the same attached window and enclosing scroll view, and never describe revealInsertionPoint returning true as complete caret resolution—the value means that scrolling occurred.

Amended candidate awaiting final reviewer approval:

  1. Dynamically scope a private one-shot marker only around the existing super.paste(sender) call. Custom host-routed image/attachment paste remains outside this scope.
  2. After the canonical display replacement performs its existing non-local immediate reveal and actually schedules its existing deferred reconciliation, arm the marker with the exact source revision, requested display range, selected range, attached window identity, and enclosing scroll-view identity.
  3. The first scrollRangeToVisible received while still inside that native paste consumes the marker regardless of match. Suppress it only if every field still matches. A changed range, revision, selection, window, or scroll view proceeds normally and cannot leave the older marker armed.
  4. The native paste defer clears any unconsumed marker. No request outside that synchronous dynamic scope can be suppressed.
  5. Keep the original immediate reveal plus one scheduled post-layout reconciliation. Capture and verify the attached window and enclosing scroll view in that scheduled closure, in addition to the existing revision/selection/editability fences.

If the first reveal cannot schedule reconciliation, do not arm the marker; AppKit's follow-up remains a recovery attempt. This confines the behavior change to the exact stack observed in the profile and leaves canonical Markdown, parsing, projection, Find, Accessibility, Undo, block selection, and navigation unchanged.

Focused regression: native full-selection paste in the real shared-scroll-view shape, followed by one main-queue settlement, must preserve exact canonical source, collapsed result selection, visible distant/EOF caret, and Undo. The existing stale-reveal, repeated-insertion, and source-mapping tests remain required. This test establishes correctness, while the exact Release A/B must establish that the AppKit duplicate subtree is removed and that latency changes beyond noise.

Reviewer outcome on the first plan: **changes required before implementation**. The retained trace proves a repeated reveal inside native `super.paste`, but it does not justify changing same-turn behavior for Find, Accessibility, Undo, navigation, or structural commands. The reviewer also identified two lifecycle requirements: fence the deferred work to the same attached window and enclosing scroll view, and never describe `revealInsertionPoint` returning `true` as complete caret resolution—the value means that scrolling occurred. Amended candidate awaiting final reviewer approval: 1. Dynamically scope a private one-shot marker only around the existing `super.paste(sender)` call. Custom host-routed image/attachment paste remains outside this scope. 2. After the canonical display replacement performs its existing non-local immediate reveal and actually schedules its existing deferred reconciliation, arm the marker with the exact source revision, requested display range, selected range, attached window identity, and enclosing scroll-view identity. 3. The first `scrollRangeToVisible` received while still inside that native paste consumes the marker regardless of match. Suppress it only if every field still matches. A changed range, revision, selection, window, or scroll view proceeds normally and cannot leave the older marker armed. 4. The native paste `defer` clears any unconsumed marker. No request outside that synchronous dynamic scope can be suppressed. 5. Keep the original immediate reveal plus one scheduled post-layout reconciliation. Capture and verify the attached window and enclosing scroll view in that scheduled closure, in addition to the existing revision/selection/editability fences. If the first reveal cannot schedule reconciliation, do not arm the marker; AppKit's follow-up remains a recovery attempt. This confines the behavior change to the exact stack observed in the profile and leaves canonical Markdown, parsing, projection, Find, Accessibility, Undo, block selection, and navigation unchanged. Focused regression: native full-selection paste in the real shared-scroll-view shape, followed by one main-queue settlement, must preserve exact canonical source, collapsed result selection, visible distant/EOF caret, and Undo. The existing stale-reveal, repeated-insertion, and source-mapping tests remain required. This test establishes correctness, while the exact Release A/B must establish that the AppKit duplicate subtree is removed and that latency changes beyond noise.
Author
Owner

Shared exact note-editor route from the valid 6ca85fd2 capture for current VM QA reuse:

  • Registered disposable vault: 6fb1e0c3-7cd4-4088-9034-f35d90bbb870 at /Users/lume/Documents/Calternal Overnight Perf QA.
  • Note: notes/editor-performance-10k-no-image-32900000.md, UUID 32900000-0000-4000-8000-000000000001.
  • Before launch, restore it from /Users/lume/Performance/editor-overnight-harness/normalized-canonical.md and require cmp success.
  • Launch the exact staged app and URL in one command: open -na "$APP" --env CALTERNAL_PERF_TRACE=1 "calternal://open/v1/vault/6fb1e0c3-7cd4-4088-9034-f35d90bbb870/note/32900000-0000-4000-8000-000000000001". Wait for indexing/navigation, then resolve the PID from the exact $APP/Contents/MacOS/Calternal path and target its exact window.

This route mounted the rendered 10k editor in the center pane even though the timeline sidebar showed 13 June. The valid run retained a 960×637 window at (0,30) and a safe body focus point around logical (350,300), followed by native Select All. The full launch command is preserved in .agents/performance-current/6ca85fd2-paste-issue13-02/processes-prelaunch.txt.

Do not launch the staged app first and then dispatch an untargeted deep link. That sequence was the explicitly invalid ...issue13-01 attempt because LaunchServices opened a second installed Calternal process; it was excluded from evidence.

Shared exact note-editor route from the valid `6ca85fd2` capture for current VM QA reuse: - Registered disposable vault: `6fb1e0c3-7cd4-4088-9034-f35d90bbb870` at `/Users/lume/Documents/Calternal Overnight Perf QA`. - Note: `notes/editor-performance-10k-no-image-32900000.md`, UUID `32900000-0000-4000-8000-000000000001`. - Before launch, restore it from `/Users/lume/Performance/editor-overnight-harness/normalized-canonical.md` and require `cmp` success. - Launch the exact staged app and URL in one command: `open -na "$APP" --env CALTERNAL_PERF_TRACE=1 "calternal://open/v1/vault/6fb1e0c3-7cd4-4088-9034-f35d90bbb870/note/32900000-0000-4000-8000-000000000001"`. Wait for indexing/navigation, then resolve the PID from the exact `$APP/Contents/MacOS/Calternal` path and target its exact window. This route mounted the rendered 10k editor in the center pane even though the timeline sidebar showed 13 June. The valid run retained a 960×637 window at `(0,30)` and a safe body focus point around logical `(350,300)`, followed by native Select All. The full launch command is preserved in `.agents/performance-current/6ca85fd2-paste-issue13-02/processes-prelaunch.txt`. Do not launch the staged app first and then dispatch an untargeted deep link. That sequence was the explicitly invalid `...issue13-01` attempt because LaunchServices opened a second installed Calternal process; it was excluded from evidence.
Author
Owner

Source candidate ready for build-owner validation; issue remains open.

  • Worktree: /Users/kayg/Developer/calternal-app/.worktrees/editor-caret-relocation-perf
  • Branch: wave16/editor-caret-relocation-perf
  • Parent: exact 37c5d40de40a2d0b279aad8d13d6f68837533c2d
  • Commit: 51628eb9 (Coalesce duplicate native paste reveal)
  • Scope: BlockEditorView.swift plus one focused editor regression; git diff --check passed. No local compilation, build-host use, or VM use.

Implementation: only the super.paste fallback opens a synchronous native-paste scope. After the canonical replacement has scrolled and enqueued its existing deferred reconciliation, it records a one-shot key containing revision, target range, selection, window, and enclosing scroll view. The first paste-time AppKit scrollRangeToVisible consumes the key and returns only on an exact match. Mismatches, failures, custom paste handlers, and every request outside super.paste keep the normal reveal path. The retained deferred reconciliation is independent and now verifies the same window and scroll view before and after host layout.

The focused async test performs native full-selection paste inside the shared-scroll hierarchy and asserts exact source, collapsed result selection, visible distant/EOF caret after reconciliation, and Undo recovery.

Independent implementation review: PASS, no P1/P2/P3 findings. The reviewer confirmed the dynamic scope, one-shot lifecycle, key, independent host-fenced reconciliation, and test route. A theoretical nested/reentrant native paste could disable coalescing for the outer call, but normal AppKit paste is non-reentrant and the outcome falls back to the original reveal behavior rather than losing correctness.

Pending: agents@mbp compile/focused tests, then exact Release A/B. Performance evidence must show whether the 39-sample AppKit duplicate subtree disappears and whether only one deferred reconciliation remains, with matched latency/source/Undo/RSS receipts. This candidate alone does not satisfy #13's selection/scroll, mixed-image, leak, launch, key-repeat, or Mailternal acceptance.

Source candidate ready for build-owner validation; issue remains open. - Worktree: `/Users/kayg/Developer/calternal-app/.worktrees/editor-caret-relocation-perf` - Branch: `wave16/editor-caret-relocation-perf` - Parent: exact `37c5d40de40a2d0b279aad8d13d6f68837533c2d` - Commit: `51628eb9` (`Coalesce duplicate native paste reveal`) - Scope: `BlockEditorView.swift` plus one focused editor regression; `git diff --check` passed. No local compilation, build-host use, or VM use. Implementation: only the `super.paste` fallback opens a synchronous native-paste scope. After the canonical replacement has scrolled and enqueued its existing deferred reconciliation, it records a one-shot key containing revision, target range, selection, window, and enclosing scroll view. The first paste-time AppKit `scrollRangeToVisible` consumes the key and returns only on an exact match. Mismatches, failures, custom paste handlers, and every request outside `super.paste` keep the normal reveal path. The retained deferred reconciliation is independent and now verifies the same window and scroll view before and after host layout. The focused async test performs native full-selection paste inside the shared-scroll hierarchy and asserts exact source, collapsed result selection, visible distant/EOF caret after reconciliation, and Undo recovery. Independent implementation review: **PASS**, no P1/P2/P3 findings. The reviewer confirmed the dynamic scope, one-shot lifecycle, key, independent host-fenced reconciliation, and test route. A theoretical nested/reentrant native paste could disable coalescing for the outer call, but normal AppKit paste is non-reentrant and the outcome falls back to the original reveal behavior rather than losing correctness. Pending: agents@mbp compile/focused tests, then exact Release A/B. Performance evidence must show whether the 39-sample AppKit duplicate subtree disappears and whether only one deferred reconciliation remains, with matched latency/source/Undo/RSS receipts. This candidate alone does not satisfy #13's selection/scroll, mixed-image, leak, launch, key-repeat, or Mailternal acceptance.
Author
Owner

Combined integration candidate — worker /root/block_drag_finish

Reviewed paste/caret coalescing commit 51628eb92208b8e980acf0ddca91d5a328397c52 was integrated conflict-free as 8d3dd56dbb76805747783ba662b1150f366dfc0c onto base 26eb1552; stable patch ID is identical (27e46fe6…). Combined tip after reviewed code-block and list-selection deltas is f99ed4f28ae3b21beb87e4a99c4bf4a05acaaae8 in .worktrees/editor-structural-combined.

Exact interaction review is active, specifically checking paste reveal scheduling against list multi-selection restoration and code-fragment layout. No local build or GUI run. Focused selectors: testCaretRevealKeepsTypedTextVisibleInSharedScrollPage, testRepeatedCaretRevealKeepsWrappedInsertionsVisibleInSharedScrollPage, testNativePasteKeepsDistantCaretVisibleAndUndoesInSharedScrollPage, and testStaleCaretRevealDoesNotOverrideNewSelectionOrFocus.

Combined integration candidate — worker `/root/block_drag_finish` Reviewed paste/caret coalescing commit `51628eb92208b8e980acf0ddca91d5a328397c52` was integrated conflict-free as `8d3dd56dbb76805747783ba662b1150f366dfc0c` onto base `26eb1552`; stable patch ID is identical (`27e46fe6…`). Combined tip after reviewed code-block and list-selection deltas is `f99ed4f28ae3b21beb87e4a99c4bf4a05acaaae8` in `.worktrees/editor-structural-combined`. Exact interaction review is active, specifically checking paste reveal scheduling against list multi-selection restoration and code-fragment layout. No local build or GUI run. Focused selectors: `testCaretRevealKeepsTypedTextVisibleInSharedScrollPage`, `testRepeatedCaretRevealKeepsWrappedInsertionsVisibleInSharedScrollPage`, `testNativePasteKeepsDistantCaretVisibleAndUndoesInSharedScrollPage`, and `testStaleCaretRevealDoesNotOverrideNewSelectionOrFocus`.
Author
Owner

Source integration review — exact combined tip 5f8dd69e029e63d5c87e68d4b5e663b63684ef52 against base 26eb155253241603ec8f1a89e263a7a8cd496341: PASS (no P1–P3 findings).

The #13/#14 paste-reveal commit has an identical stable patch to its reviewed source. Its pending marker is scoped to the synchronous native paste, revision, selection, window, and scroll view, then cleared on the first AppKit follow-up/defer. The added multi-range list restoration does not leak into that state. After a list source transaction changes the selection, the earlier deferred reveal fails its selection fence and the explicit primary-range reveal owns the current selection. No image, focus, title, or existing selection path was reverted in the combined diff.

This is a source-only integration verdict. Compile and mounted runtime verification remain with the build/QA lanes.

Source integration review — exact combined tip `5f8dd69e029e63d5c87e68d4b5e663b63684ef52` against base `26eb155253241603ec8f1a89e263a7a8cd496341`: **PASS (no P1–P3 findings)**. The #13/#14 paste-reveal commit has an identical stable patch to its reviewed source. Its pending marker is scoped to the synchronous native paste, revision, selection, window, and scroll view, then cleared on the first AppKit follow-up/defer. The added multi-range list restoration does not leak into that state. After a list source transaction changes the selection, the earlier deferred reveal fails its selection fence and the explicit primary-range reveal owns the current selection. No image, focus, title, or existing selection path was reverted in the combined diff. This is a source-only integration verdict. Compile and mounted runtime verification remain with the build/QA lanes.
Author
Owner

Root fast-forwarded the clean preview integration branch from26eb1552 to exact5f8dd69e after independent combined source review PASS and diff-check. Includes code-block presentation, atomic disjoint list indentation, native-paste reveal coalescing, and hover lifecycle/footer-width correction. The known roughly7pt visible text/mentions alignment gap remains for native measurement. This is a NEXT build candidate; it does not supersede the current26eb event/title build and is not installed. No runtime/performance acceptance is claimed.

Root fast-forwarded the clean preview integration branch from26eb1552 to exact5f8dd69e after independent combined source review PASS and diff-check. Includes code-block presentation, atomic disjoint list indentation, native-paste reveal coalescing, and hover lifecycle/footer-width correction. The known roughly7pt visible text/mentions alignment gap remains for native measurement. This is a NEXT build candidate; it does not supersede the current26eb event/title build and is not installed. No runtime/performance acceptance is claimed.
Author
Owner

Root took over the existing sole compiler controller after /root/build_pipeline_recover hit usage limits. Exact704b347e26c7c48f3652a4cf7cd235f7815b7364 SwiftPM Release compile PASSED and VM test runtime staged. Tests executed:0 so far. Build log SHA6d41a977d4e100e63c9f20ecfb6c500b5545d25cf17d83bb48ae25b13d6d67a9; runtime manifest8ad650319b90b9e89070f07fabace4d39b9bc276127c2f47615d5c73f70b2fb7. /root/image_preview_qa assigned exact runtime tests. Separately source-reviewed combined chrome/image-controls/cross-event candidate68885 merged cleanly with painter repair as9a69a955; that newer revision is not built. Each thread owns updates in its relevant issues. Desktop remains26eb1552.

Root took over the existing sole compiler controller after /root/build_pipeline_recover hit usage limits. Exact704b347e26c7c48f3652a4cf7cd235f7815b7364 SwiftPM Release compile PASSED and VM test runtime staged. Tests executed:0 so far. Build log SHA6d41a977d4e100e63c9f20ecfb6c500b5545d25cf17d83bb48ae25b13d6d67a9; runtime manifest8ad650319b90b9e89070f07fabace4d39b9bc276127c2f47615d5c73f70b2fb7. /root/image_preview_qa assigned exact runtime tests. Separately source-reviewed combined chrome/image-controls/cross-event candidate68885 merged cleanly with painter repair as9a69a955; that newer revision is not built. Each thread owns updates in its relevant issues. Desktop remains26eb1552.
Author
Owner

704b focused native-paste check: MarkdownBlockDocumentTests/testNativePasteKeepsDistantCaretVisibleAndUndoesInSharedScrollPage executed 1 test with 0 failures. This covers distant-caret visibility and shared-page Undo in the package runtime; it is not a broad image/Quick Look or desktop UI acceptance result.

704b focused native-paste check: `MarkdownBlockDocumentTests/testNativePasteKeepsDistantCaretVisibleAndUndoesInSharedScrollPage` executed 1 test with 0 failures. This covers distant-caret visibility and shared-page Undo in the package runtime; it is not a broad image/Quick Look or desktop UI acceptance result.
Author
Owner

Remote preservation checkpoint — 2026-09-14

The following original-worktree candidates are now pushed and exact hashes verified on both Forgejo and GitHub. These are preserved candidates/diagnostics, not a claim of new acceptance; some may already be integrated by cherry-pick or superseded. Use the issue’s existing evidence before choosing changes to resume.

  • wave13/editor-inline-fast-path — 6184226830e6494c32f25d91d2f75d1ddbf8a41a
  • wave16/editor-caret-relocation-perf — 51628eb92208b8e980acf0ddca91d5a328397c52

Master #20 contains the resume instructions. No force push; dev remains 1d8f4adf.

Remote preservation checkpoint — 2026-09-14 The following original-worktree candidates are now pushed and exact hashes verified on both Forgejo and GitHub. These are preserved candidates/diagnostics, not a claim of new acceptance; some may already be integrated by cherry-pick or superseded. Use the issue’s existing evidence before choosing changes to resume. - `wave13/editor-inline-fast-path` — `6184226830e6494c32f25d91d2f75d1ddbf8a41a` - `wave16/editor-caret-relocation-perf` — `51628eb92208b8e980acf0ddca91d5a328397c52` Master #20 contains the resume instructions. No force push; dev remains 1d8f4adf.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
kayg/calternal-macos#13
No description provided.