Skip to content

Avoid duplicate WebAssembly publish asset compression - #68463

Merged
wtgodbe merged 1 commit into
dotnet:mainfrom
wtgodbe:fix-webassembly-double-publish
Aug 12, 2026
Merged

Avoid duplicate WebAssembly publish asset compression#68463
wtgodbe merged 1 commit into
dotnet:mainfrom
wtgodbe:fix-webassembly-double-publish

Conversation

@wtgodbe

@wtgodbe wtgodbe commented Aug 12, 2026

Copy link
Copy Markdown
Member

Components.TestServer publishes multiple referenced WebAssembly apps that all traverse Microsoft.AspNetCore.Components.WebAssembly. Those traversals can run concurrently and compress the same static web asset output, causing the file-lock failure seen in build 1550669.

Extend the _SkipReferencedProjectPublishAssets pattern from #68085 to the shared WebAssembly project so the redundant nested traversal is skipped.

Related to #61178.

Components.TestServer publishes multiple WebAssembly apps that traverse the shared Microsoft.AspNetCore.Components.WebAssembly project. Honor the existing skip property on that nested publish path so those traversals do not concurrently compress the same static web assets.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI lite review requested due to automatic review settings August 12, 2026 19:36
@wtgodbe
wtgodbe requested a review from a team as a code owner August 12, 2026 19:36

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

This PR mitigates a known race during Components.TestServer publish where multiple referenced WebAssembly apps concurrently traverse Microsoft.AspNetCore.Components.WebAssembly and can attempt to compress the same static web asset outputs, causing intermittent file-lock failures.

Changes:

  • Adds a conditional _SkipReferencedProjectPublishAssets gate to short-circuit Static Web Assets “get publish assets” traversal for Microsoft.AspNetCore.Components.WebAssembly.
  • Introduces a no-op target (_SkipGetPublishAssetsForTrimmedBuild) used as the alternate traversal target to prevent redundant/concurrent compression.

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

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.

2 participants