You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maka.apache.org by "orangeCatDeveloper (via GitHub)" <gi...@apache.org> on 2026/09/05 08:09:57 UTC

[PR] test(desktop): drag the quote selection from a settled answer [maka]

orangeCatDeveloper opened a new pull request, #4840:
URL: https://github.com/apache/maka/pull/4840

   ## Summary
   
   `e2e/quote-selection.spec.ts:22` fails on CI about 5% of the time with the drag never producing a Selection (7 of the last ~135 E2E runs, across 7 branches including `main`).
   
   The test waits for the 重新生成 footer and then measures where to drag. On a cold Electron two more commits land after that footer, each on its own schedule: the lazy `MarkdownBody` chunk replaces the answer's plain-text Suspense fallback (`.maka-markdown-pending`, which is what the answer is while the chunk loads with progressive streaming off), and the stored turn renders with the user message's timestamp row, moving the answer down 44px. The seven CI traces split exactly along those two: four pressed the mouse at y=474 on a paragraph that ended at 517 (the timestamp row landed after measuring), three pressed on the right pixel and lost the Selection when the fallback was swapped out from under it.
   
   The test now locates the answer inside `[data-maka-contract="markdown"]`, waits for the user message's `time` element and for the transcript to be at its tail, and only then measures. All three are DOM states, not delays.
   
   Product behavior is unchanged; the fallback swap discarding a Selection is the same class of gap the file's `fixme` already records for a stream close.
   
   ## Verification
   
   Reproduced locally by throttling the renderer CPU 20× through CDP (macOS, 6 runs each):
   
   ```
   before:
       Error: expect(received).toBe(expected) // Object.is equality
       Error: expect(received).toBe(expected) // Object.is equality
       Error: quote selection source has no visible text bounds
     3 failed
     3 passed (1.0m)
   
   after:
     6 passed (41.8s)
   ```
   
   The first two failures are the CI symptom; the third is the same swap landing between locating the fallback and measuring it. Also ran the spec unthrottled ×3 (passes) and `biome check` on the file (clean).
   
   ## AI use
   
   Select exactly one:
   
   - [ ] No generative tool made a substantive contribution
   - [x] Generative tooling made a substantive contribution
   
   Tool(s) and scope: Claude Code — trace analysis of the seven CI failures, the in-page timeline probe that isolated the two late commits, the fix, and this description, under the contributor's direction; the commit carries a `Generated-by: Claude Code` trailer.
   
   ## Checklist
   
   - [x] Tests cover the change and fail without it
   - [x] Lint, format, typecheck and the affected suites pass locally
   
   Does this PR entail a change in behavior?
   
   - [ ] Yes — described under Summary above
   - [x] No
   
   https://claude.ai/code/session_01RLZUUq5ri1bHzydQ7tw32b
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] test(desktop): drag the quote selection from a settled answer [maka]

Posted by "Astro-Han (via GitHub)" <gi...@apache.org>.
Astro-Han merged PR #4840:
URL: https://github.com/apache/maka/pull/4840


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org


Re: [PR] test(desktop): drag the quote selection from a settled answer [maka]

Posted by "Astro-Han (via GitHub)" <gi...@apache.org>.
Astro-Han commented on PR #4840:
URL: https://github.com/apache/maka/pull/4840#issuecomment-5551120144

   LGTM!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@maka.apache.org
For additional commands, e-mail: commits-help@maka.apache.org