Skip to content

Stabilize AppHost tree discovery E2E - #19276

Merged
Adam Ratzman (adamint) merged 1 commit into
microsoft:mainfrom
adamint:adamint/fix-apphost-tree-discovery-e2e
Aug 12, 2026
Merged

Adam Ratzman (adamint) merged 1 commit into
microsoft:mainfrom
adamint:adamint/fix-apphost-tree-discovery-e2e

Conversation

@adamint

Copy link
Copy Markdown
Member

Description

The AppHost tree E2E could time out while waiting to observe a transient repository loading state even though the running AppHost was already visible. An existing describe --follow update could clear that state between the test's polling intervals.

This replaces the transient-state dependency with durable marker files that confirm the fresh ps and ls requests have reached their gates. The test then verifies the intended behavior: the running AppHost remains visible before slow workspace discovery produces a candidate.

Validation:

  • extension/build.sh
  • Targeted E2E launch-profile regression test
  • TypeScript E2E compilation and extension lint
  • Formerly flaky E2E scenario: 5/5 repetitions on the original PR head and 3/3 repetitions from current main

Fixes # (issue)

Checklist

  • Is this feature complete?
    • Yes. Ready to ship.
    • No. Follow-up changes expected.
  • Are you including unit tests for the changes and scenario tests if relevant?
    • Yes
    • No
  • Did you add public API?
    • Yes
      • If yes, did you have an API Review for it?
        • Yes
        • No
      • Did you add <remarks /> and <code /> elements on your triple slash comments?
        • Yes
        • No
    • No
  • Does the change make any security assumptions or guarantees?
    • Yes
      • If yes, have you done a threat model and had a security review?
        • Yes
        • No
    • No

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 10fd3379-b660-428c-b696-27e8c03d6d3f
Copilot AI balanced review requested due to automatic review settings August 12, 2026 04:51
@github-actions

Copy link
Copy Markdown
Contributor

🚀 Dogfood this PR with:

⚠️ WARNING: Do not do this without first carefully reviewing the code of this PR to satisfy yourself it is safe.

curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 19276

Or

  • Run remotely in PowerShell:
iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 19276"

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Stabilizes AppHost tree E2E synchronization by replacing transient loading-state polling with durable request markers.

Changes:

  • Add marker-backed gates for fresh ps and ls requests.
  • Assert the running AppHost remains visible while discovery is gated.
  • Update regression checks for the new ordering.
Show a summary per file
File Description
extension/src/test/e2eLaunchProfile.test.ts Validates durable gate usage and ordering.
extension/src/test-e2e/helpers/fixtures.ts Adds request marker files and wait helpers.
extension/src/test-e2e/appHostTree.e2e.test.ts Uses durable gates instead of transient loading state.

Review details

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

  • Files reviewed: 3/3 changed files
  • Comments generated: 0
  • Review effort level: Balanced

@adamint
Adam Ratzman (adamint) merged commit d1c7add into microsoft:main Aug 12, 2026
364 checks passed
@github-actions github-actions Bot added this to the 13.6 milestone Aug 12, 2026
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ CI Failure Analysis: Mixed Failures

The CI build contains both transient and non-transient failures.

Failed jobs:

  • Tests / Hosting.Sdk / Hosting.Sdk (windows-latest) — All 52 tests passed (0 failed) before the job crashed. Post-test steps failed with exit code -1073741502 (0xC0000142 STATUS_DLL_INIT_FAILED), a known Windows runner process initialization failure unrelated to any test or PR code. (transient-infra)
  • Tests / Run VS Code extension E2E tests / VS Code extension E2E (Linux, apphost-tree) — The failing test 'Aspire AppHost tree E2E running AppHosts appear before slow discovery results' timed out waiting for a tree item, in the exact test file (appHostTree.e2e.test.ts) and fixtures (fixtures.ts) that this PR modified in order to stabilize this E2E test. The PR's own stabilization attempt did not fully resolve the flakiness/timing issue. (code-issue)

The CI will not be automatically rerun. Please review the failures above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants