Skip to content

fix(ui): dispose deferred FlowCanvas callbacks and test roots - #16689

Merged
diegosouzapw merged 5 commits into
release/v3.8.52from
fix/relay-flow-timer-20261015
Oct 15, 2026
Merged

diegosouzapw merged 5 commits into
release/v3.8.52from
fix/relay-flow-timer-20261015

Conversation

@diegosouzapw

Copy link
Copy Markdown
Collaborator

Summary

  • Cancel deferred FlowCanvas initialization fits on teardown and ignore initializers from disposed graph identities, including a -> b -> a key reuse.
  • Preserve fitting for active/replacement graphs and React StrictMode replay.
  • Properly unmount CompressionCockpit test roots before removing their DOM containers, allowing React/React Flow cleanup to execute.

Reuses three existing, unpublished lifecycle fixes with cherry-pick -x; the original branch/worktree and original commit authors are preserved. No timeout, assertion, baseline, or gate relaxations.

Evidence

Pinned base: 88c1e3342b44978a72ce75beb0cc509cc83a93d2.

  • Current hosted base-candidate signature: CI run 38725669414, job 116391388505, reported 11 unhandled window is not defined errors in the deferred FlowCanvas onInit fit despite passing UI assertions.
  • Seven lifecycle regression tests on the unchanged base: 4 FAIL / 3 PASS, with real lifecycle assertions rather than timeout failures.
  • Four relevant UI suites after lifecycle and test-root cleanup: 37/37 PASS, zero unhandled errors, using the actual Vitest UI collector with one worker and unchanged timeouts.
  • Earlier parallel diagnostic: 35/37 PASS, two 5s test timeouts and two late React scheduler errors. This led to fixing the missing CompressionCockpit root cleanup, not raising timeouts.
  • Scoped formatting, lint, and normal commit hooks PASS.

The local dependency tree matches the candidate lockfile but was copied from a prior diagnostic install. Focused evidence is not full release or merge acceptance. Hosted required checks must validate the exact current candidate; known unrelated base API typecheck/file-size/unit/doc failures are being repaired separately. No queue label or bypass requested.

Part of the owner-approved ordered Relay closeout and base-red incident #15306.

@diegosouzapw

Copy link
Copy Markdown
Collaborator Author

Final lifecycle review found one additional timing window: a keyed graph was already disposed while its replacement's deferred onInit was still pending. The old ref and both queued fit paths could remain reachable until that callback arrived.

  • New regression on the previous PR head: 1 FAIL / 7 PASS, with two observed calls into the disposed instance.
  • Invalidate the generation, initialization timer and instance ref immediately when graph identity changes.
  • Exact focused UI collector after the fix: 38/38 PASS across four files, zero unhandled errors, one worker, unchanged timeouts/assertions.
  • Scoped formatting and lint PASS. Original reused commits and contributor attribution remain intact.

This strengthens the earlier 37-test evidence; it does not claim full current-base CI acceptance. No queue label or administrative bypass applied.

@github-actions

Copy link
Copy Markdown
Contributor

CI Coverage Report

  • Coverage job: skipped
  • PR test policy: success

Coverage artifact was not available for this run.

@diegosouzapw
diegosouzapw merged commit 57ff922 into release/v3.8.52 Oct 15, 2026
36 of 50 checks passed
@diegosouzapw
diegosouzapw deleted the fix/relay-flow-timer-20261015 branch October 18, 2026 23:50
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