Skip to content

fix: preserve stale ProjectPanel reclamp proof with concurrent halo RAF #3107

Closed

Description

@mblua

The stale same-session reclamp test in src/sidebar/components/ProjectPanel.context-menu.test.tsx assumes that a global requestAnimationFrame spy captures exactly one callback. Continuous halo tracking can register another callback, so the test fails before executing the old reclamp and observing the reopened menu.

PR #3102 is blocked by run39089324848 attempts1/2, jobs117562485792/117573009963: both4108 passed/1 failed, assertion2054 sees [clamp,tick]. The same failure was already recorded in P02 b7033fb (run39076334013/job117524163380); no attribution to P03 or a particular team is established. PR #3076 adapted a neighboring positive reclamp test, but not this stale callback case. Existing reds must remain preserved.

Approved scope: change only the existing stale callback case, keeping the number of tests unchanged. Capture a finite non-empty callback snapshot before closing menu A, retain it through reopening B for the same session, then execute the old snapshot once after B's listeners/geometry are prepared. Preserve all functional assertions, including position, node identity, labels, absent bot options, listeners and later dismissal. Do not select callbacks by name/index, filter unknown ticks, drain the recurring queue, or change product behavior/New Team.

Acceptance:

  1. The corrected stale case and existing positive reclamp case pass.
  2. A temporary isolated mutation removing only the epoch comparison must make the stale case fail specifically on B's position. A green mutant or unrelated failure does not establish sensitivity.
  3. Always attempt restoring the runtime guard after the control process terminates, including unexpected failure/timeout/cancellation; verify its bytes and the final diff. Never publish a mutant.
  4. The complete context-menu test file passes after restoration. Final permanent diff is confined to this one test case.
  5. Applicable frontend CI runs on Linux with the actual configured reporters/concurrency on the exact delivery SHA; no duplicate equivalent full local suite, retry-to-green, debt exemption or threshold/config change.

Investigation: .ac/project-shared/pr3102-investigation/report-v1.md and preserved logs. Approved solution: .ac/plans/pr3102-projectpanel-raf/plan-v5-projectpanel-raf.md v5/r1, SHA25615c1dd3b0b51c4348585d2a05ce14febaf43edceb1d7bae5f388d7dabd52d4bc, exact four-party consensus in consensus-v5-r1.md. User explicitly approved execution in the current conversation. An immutable execution-ready plan revision will record this approval and the issue mapping without changing the solution.

Current own-repo base:103ecbdfed5c6a3b2c6a8d54f441fb127e3ff6bf. Target inputs (both ProjectPanel files, harness, vitest, package/lock and regression workflow) are unchanged from the investigated PR head/CI checkout. Deliver through a separate issue branch/PR, not PR3102's branch or room24's checkout. This issue does not implement New Team or close #3073.

Activity

  1. added
    bugSomething isn't working
    linuxAffected platform: the behaviour occurs on or is specific to Linux
    on Oct 18, 2026
  2. mblua commented on Oct 18, 2026

    @mblua
    OwnerAuthor

    Technical sizing for #3107 (unchanged from approved plan): 9/100, raw26.

    Category Points Anchor/evidence
    Scope footprint 1 Anchor1: one existing case/file, a handful of lines.
    Diagnosis difficulty 1 Anchor1: faulty global-cardinality precondition already identified. Dynamic tick ownership is not needed for this repair.
    Domain knowledge 2 Near anchor1: ordinary TypeScript/DOM callbacks.
    Solution-space ambiguity 1 Anchor1: one concrete reviewed snapshot adaptation.
    Blast radius/reversibility 1 Anchor1: isolated reversible test-only final diff.
    Dependency/integration load 1 Anchor1: no runtime/API/dependency change.
    Verification difficulty 8 Existing harness below new-test anchor10, with discriminating epoch mutation required to exclude vacuous green.
    State/compatibility 1 Anchor1: no persisted state/formats.
    Concurrency/timing 5 Below async ownership anchor10: finite batch, explicit A-close-B order.
    Environment/tooling 5 Below platform-specific anchor10: known Linux CI inputs, no environment repair.

    round((26-10)/190*99)+1=9. Ceremony excluded: issue, branch, PR, messaging, review rounds, CI waiting, merge and cleanup. Lite, one test file; verification>=8 requires reviewing sensitivity evidence as well as diff. No Full criterion or partition. Original plan's provisional sizing is now published on its execution issue; this does not permit bypassing readiness/consensus gates.

  3. mblua commented on Oct 18, 2026

    @mblua
    OwnerAuthor

    Remaining upstream-main qualification: technical9/100, raw26. Same calibrated categories as original3107; zero permanent product changes, only bounded existing-test sensitivity and restoration.

    • Footprint1: anchor handful of lines/localfile; two temporary files, no permanentcode.
    • Diagnosis1: specificmissingepochproof identified, notdiagnosingRust.
    • Domain2: familiarSolid/Vitestcallbackfixture, below subsystemanchor10.
    • Ambiguity1: epoch-onlynegative/restoredexistingcase, no productdesignchoice.
    • Blast/reversibility1: byte-backed ownedtemporarysource, localrestore, no publishedmutant.
    • Integration1: selfcontained existingrepo/runner/dependencies; no teamcontractchange.
    • Verification8: calibrated #1702positivecontrolanchor8; mutation mustfailposition andrestoredmustpass, sourceidentityqualified.
    • State1: no persistedapplicationstate/migration.
    • Concurrency5: knownasyncRAF/dismissfixture, controlledframes, below sharedownershipanchor10.
    • Environment5: existingWindowsNode/npm andboundedrunner; frontendinputidentity vsmain needed, no newtooling/platformfix.
      Normalization round((26-10)/190*99)+1=9. Excludes allissue/PR/merge/CIwaiting/messaging/review/purge/planround ceremony. Verification>=8 requires independent reviewofproof. Lite/verification-only remainingdelta; UIauthor under lowband, bothGrinches plus architect as originalfourparticipants required byRole. No scorechange solely foradministrativeworkflow.
  4. mblua commented on Oct 18, 2026

    @mblua
    OwnerAuthor

    Superseded by the existing correction in a77f8a8, landed through #3056 and present in main 3b73455c4b8feccb53aaa2588b2153d505da73d6. Closing this competing PR without merging or deleting its branch/history.

    The existing fix intercepts RAF before setup and isolates the settings-response request interval. It retains a strict one-request assertion for that controlled interval and all reopened-menu checks; it does not depend on a global single RAF. The saved stale callback is delivered deliberately after the same session reopens, even if cancelled. See test:2025 and epoch guard:1526.

    Missing mutation proof has now been obtained under exact four-party consensus on plan v10/r1, SHA256 81f584d54ac89edc9b00e89aefbe92cbf2434567b87278828b205af48208f999:

    • Epoch comparison alone removed (kind/session retained): one bounded negative, exit1, B position fails at test2100:38: 8px versus 210px. Capture/cardinality passed first.
    • Runtime restored: one bounded focal, exit0, stale + existing expanded-menu positive both PASS. No retries or new permanent tests; all108 file cases remain.
    • Both source originals restored byte-for-byte, HEAD/branch unchanged, staged content unchanged and clean checkout. Known child/writer processes settled. Both independent proof reviews PASS; all21 artifact hashes checked. Raw index byte identity is unverified; staged identity is verified. No claim about the cause of the index digest delta.

    Accurate execution attribution: Windows Node22.23.3/npm11.6.2, actual HEAD 23348634913386cc2aaf2efe87d22354d3d5ecdd plus exact main3b test blob 9da44f167b85dfe3a8e083609c6377e1bfada1ae, with relevant frontend-input equivalence verified. This is not a whole-main/Linux/Rust/CI qualification.

    Historical failures remain red, including PR3102 run39089324848 attempts1/2 and our required Windows Rust failure run39153632740. That Rust cause remains UNKNOWN and unrepaired. Original [clamp,tick] dynamic tick ownership/frequency remains unknown; P02 preexistence means P03 is not necessary to produce it. This closure bypasses no red check because no merge occurs.

    Room24 receives the qualified existing main fix and retains responsibility for its own integration and exact-HEAD validation. This does not declare PR3102 green or authorize more retries. #3107 is fulfilled by the already-landed correction and this accepted proof.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingdeveloped-windowsDeveloped on Windows.linuxAffected platform: the behaviour occurs on or is specific to Linux

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions