Skip to content

fix: stop hiding the cause of native desktop fixture failures - #2221

Merged
yansfil merged 4 commits into
mainfrom
fix/flaky-desktop-fixture
Nov 8, 2026
Merged

yansfil merged 4 commits into
mainfrom
fix/flaky-desktop-fixture

Conversation

@yansfil

@yansfil yansfil commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor

Closes with-hide/hide-private#291

Refs with-hide/hide-private#130 (남은 증상이 있어 열어 둠), Refs with-hide/hide-private#537 (제품 경합은 with-hide/hide-private#722), #515는 코어 라벨 적용 문제로 따로 남김 (with-hide/hide-private#515)

Summary

데스크톱 e2e 여섯 개가 실패하면 AggregateError: ... fixture or teardown failed 한 줄만 남아서, 이슈 네 개가 몇 주 동안 원인을 적지 못했습니다.
실제 원인은 job 로그 안쪽에 있었고 서로 달랐습니다.

Review

  • 판단해 주세요: #515는 이 PR에서 닫지 않습니다. 10회 반복에서 session-workflow가 4번 실패했고, 실패마다 자식 행의 문구(record_summary)는 있는데 부모의 raised ask what이 null이며 30초가 지나도 바뀌지 않습니다(지연이 아니라 고정된 상태). 코어의 라벨 적용(hide-core/src/labels/overlay.rs, label.proves)을 의심하지만 확정하지 못했습니다. 제품 수정은 별도 PR로 가야 합니다.
  • 알아 두세요: #537의 제품 경합(hide-core/src/runtime/operations.rs의 queue_pane_close는 several을 엔진이 확정한 레이아웃으로 정해, 분할이 확정되기 전에 원래 pane을 닫으면 대기열을 건너뜀)은 이 PR에서 바꾸지 않았고 with-hide/hide-private#722에서 다룹니다.
  • 조심해서 볼 파일: desktop/src/main/host.ts - 호스트의 failure path입니다. 요청을 inBackground로 보내도 로그 이름과 필드는 그대로입니다.
  • 조심해서 볼 파일: web/e2e/daemon-actions.ts - splitPane은 web e2e 세 스펙과 데스크톱 세 스펙이 함께 씁니다. 탭의 지오메트리 작업이 비는 것을 기다립니다.
  • 조심해서 볼 파일: web/e2e/engine-fixture.ts - 가족 픽스처가 hide agent show here를 폴링합니다. 읽기 전용 호출이고 스폰은 한 번만 보냅니다.

Evidence

  • 확인한 것: 네 이슈의 CI 로그와 아티팩트를 읽어 안쪽 첫 실패를 찾았습니다. Open the Recent palette only after the clicked checkout is in front #515 네 run 모두 같은 Stopped at a permission request, Make ⌘K a navigation palette for agents, projects, issues and pull requests #291 markResourceTiming, Flaky test: the Explorer creates, renames, moves and trashes entries #537 분할 확정 전에 나간 닫기입니다. #130은 기록된 run 9개 중 3개가 agent_pane_required(Windows 2, macOS 1)이고, macOS 4개는 session-work-ledger.spec.ts:44 hover() 다음 클릭이 "element is not visible"로 시간 초과, Windows 1개는 launchShell relaunch 시간 초과입니다. 뒤의 두 증상은 이 PR이 고치지 않았습니다.
  • 확인한 것: 데스크톱 타입체크, 린트, 단위 테스트(30개 파일, 315개 통과)와 웹 타입체크, 린트가 통과했습니다. 새 단위 테스트는 finishNative 5개, inBackground 3개입니다.
  • 확인한 것: CI 전체가 통과했습니다(desktop e2e macos 1/2, 2/2 포함).
  • 확인한 것: 임시 ref에서 macOS 반복 실행(--repeat-each 10 --retries 0, 스펙 7개)을 돌렸습니다. 6개 스펙(agent-handoff, agent-spawn, session-work-ledger, usage, usage-history, restoration)은 10번 모두 통과했습니다. session-workflow는 6/10이고 실패 4번은 모두 #515의 증상입니다.
  • 확인하지 못한 것: #515의 원인. 이 Mac mini에는 빌드가 없고 부하가 커서 e2e를 로컬에서 돌리지 못했습니다.
  • 확인하지 못한 것: #537의 로그는 Herdr 엔진 시절 것이고 Herdr 제거(2026-11-05) 뒤 재발은 없습니다. 같은 경합이 코어 코드에 남아 있어 픽스처만 고쳤고, 현재 엔진에서 재현하지는 못했습니다.
Verification record
  • base: main a558c20dd, head: 이 PR의 head
  • bash scripts/verify-web.sh desktop typecheck|lint|test, web typecheck|lint 통과
  • python3 scripts/merge-order.py --branch fix/flaky-desktop-fixture: 겹치는 열린 PR 없음, Stay as you are

… an unhandled rejection

The host's background requests (the Hide AI wake after attaching, the
browser route release) chained a catch onto fetch's result. The first fetch
in a process loads its HTTP client, and a load that fails throws from the
call itself, so the catch never saw it: the throw left sendWake inside the
discovery that attached the window and surfaced as an unhandled rejection,
which the fixture's host log check turned into a failed handoff test.

Both requests now go through inBackground, which runs the call inside the
guard and ends every failure in the caller's log line.
…ts fixture steps need

Six native specs threw one AggregateError over their body and their
teardown. The flaky report and the history classifier read the error's
first line and its located expect diagnostic, both inside a nested error,
so four issues named no cause. finishNative throws the first failure
itself and appends each failed teardown step by name.

The causes the job logs showed, each a step that went on before the core
had acted:
- the family fixture spawned its child once the parent's row named its
  session, before the delivery observation that lets the pane call spawn
  existed (agent_pane_required); it now polls the read-only agent show.
- splitPane returned on the pane the core drew ahead of the engine, so a
  close sent next ran beside the split and was never answered; it now
  waits for the tab's geometry line to empty.
- the task list spec read the parent's second line after the page's own 5 s
  limit; it now waits for the label line on the parent's raised ask and
  dumps both rows when that gives up.
…de from the answer, and pair the geometry phases with the core's
@yansfil
yansfil added this pull request to the merge queue Nov 8, 2026
Merged via the queue into main with commit f874e8e Nov 8, 2026
82 checks passed
@yansfil
yansfil deleted the fix/flaky-desktop-fixture branch November 8, 2026 01:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant