Skip to content

test(support): bound recomposer teardown in draft reactivation test - #507

Merged
veryCrunchy merged 1 commit into
mainfrom
fix/support-settings-reactivation-test-hang
Oct 15, 2026
Merged

veryCrunchy merged 1 commit into
mainfrom
fix/support-settings-reactivation-test-hang

Conversation

@veryCrunchy

Copy link
Copy Markdown
Member

Outcome

Test-only change with no user-visible effect. SupportSettingsDraftReactivationTest can no longer hang the desktop test suite.

The test drove a manual Recomposer with one BroadcastFrameClock frame per step and then waited for idle without a bound. Earlier desktop UI tests leave Compose's global snapshot manager applying snapshots on the UI dispatcher. That can notify the recomposer after the single frame was sent, so it waits for a frame that never comes. Teardown then called Recomposer.close() and joined without a bound. In Compose 1.11, close() does not resume a runner that is waiting for a frame while an effect is still completing, so the join never returned.

The test now:

  • keeps sending frames while recomposition is pending, with every composition wait bounded at 5 s and a stage-specific failure message;
  • stops the recomposer with cancel() and a bounded join, cancelling the runner as a fallback;
  • always runs account cleanup, and reports teardown failures without hiding the test's own failure.

Assertions are unchanged. AdministrationAccessCompositionTest, the only other manual Recomposer test, already sends frames continuously and uses cancel(), so it is unchanged.

This is the likely cause of an intermittent :ui:desktopTest hang seen locally and of one Linux CI job timeout. The mechanism and the hang's thread dump match, but the real-suite hang was not caught directly.

Verification

  • Every check relevant to the changed scope passes, or each unrun check is listed below with a reason

  • bash tools/check-repository.sh passes

  • A new changes/unreleased/ fragment records the change

  • No credentials, private server data, machine-local paths, or generated output are included

  • :ui:desktopTest --rerun --tests '*SupportSettingsDraftReactivationTest': 12 of 12 separate runs passed.

  • Full :ui:desktopTest :androidApp:testDebugUnitTest (both executed): desktop 3862 tests, 0 failures, 69 skipped; Android 1167 tests, 0 failures.

  • bash tools/check-kotlin-architecture.sh and bash tools/check-repository.sh pass.

  • Local runs on Windows with JDK 21.

Compatibility and risk

Desktop test code only. No production, platform, or server behavior changes.

Visual changes

Not applicable.

The reactivation test sent a single frame per step and then waited for the
recomposer to become idle without a bound. Apply notifications that arrive on
another thread, such as from the desktop global snapshot manager started by
earlier UI tests, can resume the recomposer after that frame was sent, so it
waits for a frame that never comes. The outer timeout then ran the teardown,
where Recomposer.close() does not resume a runner waiting for a frame while
an effect is still completing, and the unbounded join hung the test worker.

Keep sending frames while recomposition is pending, bound every composition
wait with a stage-specific failure, and stop the recomposer with cancel()
followed by a bounded join that cancels the runner as a fallback.
@obiente-cloud
obiente-cloud Bot temporarily deployed to Obiente Preview / PR #507 / NC Native October 15, 2026 00:38 Destroyed
@obiente-cloud

obiente-cloud Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Obiente preview

NC Native · 09d7ffb90778 · Removed

View preview status

View in Obiente

Obiente updates this comment as the preview changes.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-15T00:41:25.096609Z 09d7ffb PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@veryCrunchy
veryCrunchy merged commit 7328477 into main Oct 15, 2026
5 checks passed

This branch was successfully deployed

No deployments
Obiente Preview / PR #507 / NC Native — 09d7ffb9 Deployed Oct 15, 2026 by obiente-cloud[bot]
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