Mail layout flow cannot render its prepared-image fixture #1316

Open
opened 2026-10-07 04:42:09 +00:00 by kayg · 2 comments
Owner

Merge32 (#1122), head 5569ecdee, reproduces restyle-mailmoney's prepared-image stopping point.

Command: CALTERNAL_E2E_MAC=1 CALTERNAL_E2E_ASSET_OVERRIDE=1 bun e2e/mail-layouts.mjs.

The layout flow passes its message navigation, reader-height, columns/split/morph and responsive light/dark checks. After the prepared-images fixture update, it fails:

TimeoutError: waitFor: Timeout 30000ms exceeded.
- waiting for locator('.mail-reader-content iframe:not([aria-hidden])').first().contentFrame().locator('img').last() to be visible

The fixture writes data-URL images into body_html_raw, clears prepared bodies/resource IDs and resets html_policy_version=0. The real reader must prepare that content before images exist. Inspect the fixture's preparation contract and the worker, rather than weakening the assertion or treating this automatically as SLOW-only.

The origin/dev 3601719b8 comparison stopped earlier in assertRenderedTheme with a 30-second html evaluate timeout, so reproduction of this exact image failure on baseline is unconfirmed. Both comparisons use production web assets with the same prebuilt bash-security server binary. No assertion or fixture was changed to make this pass.

Merge32 (#1122), head 5569ecdee, reproduces restyle-mailmoney's prepared-image stopping point. Command: `CALTERNAL_E2E_MAC=1 CALTERNAL_E2E_ASSET_OVERRIDE=1 bun e2e/mail-layouts.mjs`. The layout flow passes its message navigation, reader-height, columns/split/morph and responsive light/dark checks. After the `prepared-images` fixture update, it fails: ``` TimeoutError: waitFor: Timeout 30000ms exceeded. - waiting for locator('.mail-reader-content iframe:not([aria-hidden])').first().contentFrame().locator('img').last() to be visible ``` The fixture writes data-URL images into `body_html_raw`, clears prepared bodies/resource IDs and resets `html_policy_version=0`. The real reader must prepare that content before images exist. Inspect the fixture's preparation contract and the worker, rather than weakening the assertion or treating this automatically as SLOW-only. The origin/dev 3601719b8 comparison stopped earlier in `assertRenderedTheme` with a 30-second `html` evaluate timeout, so reproduction of this exact image failure on baseline is unconfirmed. Both comparisons use production web assets with the same prebuilt bash-security server binary. No assertion or fixture was changed to make this pass.
Author
Owner

Focused origin/dev probe after the full baseline theme timeout: retain all setup and prepared-image assertions, omit only the layout capture matrix. The probe stops with AssertionError: unknown fixture action: prepared-images at the fixture exit-code assertion.

The origin/dev fixture does contain the prepared-images update, but it then falls through to a separate if action == "seed" / elif / else chain and exits as unknown. The merged tree has the elif action == "seed" fix, so it reaches the later image wait. Thus Mail fails on both trees, at different steps. The exact image rendering failure is not established on baseline. This focused probe changes no assertion or fixture and its temporary runner diff is retained in artifacts/merge32/baseline-probe.diff.

Focused origin/dev probe after the full baseline theme timeout: retain all setup and prepared-image assertions, omit only the layout capture matrix. The probe stops with `AssertionError: unknown fixture action: prepared-images` at the fixture exit-code assertion. The origin/dev fixture does contain the prepared-images update, but it then falls through to a separate `if action == "seed"` / elif / else chain and exits as unknown. The merged tree has the `elif action == "seed"` fix, so it reaches the later image wait. Thus Mail fails on both trees, at different steps. The exact image rendering failure is not established on baseline. This focused probe changes no assertion or fixture and its temporary runner diff is retained in artifacts/merge32/baseline-probe.diff.
Author
Owner

#1316 root cause is the fixture. DESIGN §45/#726 prepares images at delivery; opening a message does not enqueue work. The fixture reset html_policy_version to 0 but omitted delivery's mail.remote-content job. It now queues both bounded slots in the same fixture transaction.

The real-server production run reaches all original image assertions: all 17 render and decode, no sender URL is requested by the browser, the frame encloses its natural body and exceeds 3000px. It then exposed another fixture defect: local Mac emulation made platform non-configurable, so the shared asset seam's init script threw in every reader frame. The runner now reuses emulateMacPlatform; its focused duplicate-install regression passes:

# tests 1
# pass 1
# fail 0

Atomic commit: test(mail): queue delivery preparation for image review fixtures. A complete rerun with this branch's server follows after the workspace build. Current borrowed-server evidence and macOS screenshot matrix are under artifacts/merge32b/mail and mail-layouts.log. No Mail product code or image expectation changed.

#1316 root cause is the fixture. DESIGN §45/#726 prepares images at delivery; opening a message does not enqueue work. The fixture reset html_policy_version to 0 but omitted delivery's mail.remote-content job. It now queues both bounded slots in the same fixture transaction. The real-server production run reaches all original image assertions: all 17 render and decode, no sender URL is requested by the browser, the frame encloses its natural body and exceeds 3000px. It then exposed another fixture defect: local Mac emulation made platform non-configurable, so the shared asset seam's init script threw in every reader frame. The runner now reuses emulateMacPlatform; its focused duplicate-install regression passes: ```text # tests 1 # pass 1 # fail 0 ``` Atomic commit: test(mail): queue delivery preparation for image review fixtures. A complete rerun with this branch's server follows after the workspace build. Current borrowed-server evidence and macOS screenshot matrix are under artifacts/merge32b/mail and mail-layouts.log. No Mail product code or image expectation changed.
Commenting is not possible because the repository is archived.
No labels
No milestone
No project
No assignees
1 participant
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-v0#1316
No description provided.