Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[mono][workload] Cross compiler pack fails to install on browser due to permission setting #54612

Closed
lewing opened this issue Jun 23, 2021 · 3 comments · Fixed by #54693
Closed
Labels
arch-wasm WebAssembly architecture area-Build-mono
Milestone

Comments

@lewing
Copy link
Member

lewing commented Jun 23, 2021

The permission setting fix broke wasm workloads

dotnet workload install -v:d microsoft-net-sdk-blazorwebassembly-aot

Skip NuGet package signing validation. NuGet signing validation is not available on Linux or macOS https://aka.ms/workloadskippackagevalidation .
Updated advertising manifest microsoft.net.sdk.tvos.
Updated advertising manifest microsoft.net.sdk.android.
Updated advertising manifest microsoft.net.sdk.maui.
Updated advertising manifest microsoft.net.sdk.macos.
Updated advertising manifest microsoft.net.sdk.maccatalyst.
Updated advertising manifest microsoft.net.sdk.ios.
Updated advertising manifest microsoft.net.workload.mono.toolchain.
Installing workload manifest microsoft.net.sdk.tvos version 15.0.100-ci.upload-download-dotnettests.46.
Installing workload manifest microsoft.net.sdk.android version 30.0.100-preview.6.51.
Installing workload manifest microsoft.net.sdk.maui version 6.0.100-preview.6.874+sha.28d1f1d25-azdo.4904039.
Installing workload manifest microsoft.net.sdk.macos version 12.0.100-ci.upload-download-dotnettests.46.
Installing workload manifest microsoft.net.sdk.maccatalyst version 15.0.100-ci.upload-download-dotnettests.46.
Installing workload manifest microsoft.net.sdk.ios version 15.0.100-ci.upload-download-dotnettests.46.
Installing workload manifest microsoft.net.workload.mono.toolchain version 6.0.0-preview.7.21323.3.
Installing pack Microsoft.NET.Runtime.WebAssembly.Sdk version 6.0.0-preview.7.21323.3...
Writing workload pack installation record for Microsoft.NET.Runtime.WebAssembly.Sdk version 6.0.0-preview.7.21323.3...
Installing pack Microsoft.NETCore.App.Runtime.Mono.browser-wasm version 6.0.0-preview.7.21323.3...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.Mono.browser-wasm version 6.0.0-preview.7.21323.3...
Installing pack Microsoft.NETCore.App.Runtime.AOT.Cross.browser-wasm version 6.0.0-preview.7.21323.3...
Workload installation failed, rolling back installed packs...
Installing workload manifest microsoft.net.sdk.tvos version 14.5.100-ci.main.723.
Installation roll back failed: Failed to install manifest microsoft.net.sdk.tvos version 14.5.100-ci.main.723: The transaction has aborted..
Rolling back pack Microsoft.NET.Runtime.WebAssembly.Sdk installation...
Uninstalling workload pack Microsoft.NET.Runtime.WebAssembly.Sdk version 6.0.0-preview.7.21323.3.
Rolling back pack Microsoft.NETCore.App.Runtime.Mono.browser-wasm installation...
Uninstalling workload pack Microsoft.NETCore.App.Runtime.Mono.browser-wasm version 6.0.0-preview.7.21323.3.
Rolling back pack Microsoft.NETCore.App.Runtime.AOT.Cross.browser-wasm installation...
Workload installation failed: chmod: /tmp/Microsoft.NETCore.App.Runtime.AOT.Cross.browser-wasm-6.0.0-preview.7.21323.3-extracted/tools/opt: No such file or directory

install
  Install a workload.

Usage:
  dotnet [options] workload install [<WORKLOAD_ID>...]

Arguments:
  <WORKLOAD_ID>  The NuGet Package Id of the workload to install.

Options:
  --sdk-version <VERSION>                                                  The version of the SDK.
  --configfile <FILE>                                                      The NuGet configuration file to use.
  --add-source <SOURCE>                                                    Add an additional NuGet package source to use during installation.
  --skip-manifest-update                                                   Skip updating the workload manifests.
  --from-cache <from-cache>                                                Complete the operation from cache (offline).
  --download-to-cache <download-to-cache>                                  Download packages needed to install a workload to a folder which can be used for offline installation.
  --include-previews                                                       Allow prerelease workload manifests.
  --temp-dir <temp-dir>                                                    Configure the temporary directory used for this command (must be secure).
  --disable-parallel                                                       Prevent restoring multiple projects in parallel.
  --ignore-failed-sources                                                  Treat package source failures as warnings.
  --no-cache                                                               Do not cache packages and http requests.
  --interactive                                                            Allows the command to stop and wait for user input or action (for example to complete authentication).
  -v, --verbosity <d|detailed|diag|diagnostic|m|minimal|n|normal|q|quiet>  Set the MSBuild verbosity level. Allowed values are q[uiet], m[inimal], n[ormal], d[etailed], and diag[nostic].
  -?, -h, --help                                                           Show help and usage information

cc @steveisok @directhex

@lewing lewing added arch-wasm WebAssembly architecture area-Build-mono labels Jun 23, 2021
@ghost
Copy link

ghost commented Jun 23, 2021

Tagging subscribers to 'arch-wasm': @lewing
See info in area-owners.md if you want to be subscribed.

Issue Details

The permission setting fix broke wasm workloads

dotnet workload install -v:d microsoft-net-sdk-blazorwebassembly-aot

Skip NuGet package signing validation. NuGet signing validation is not available on Linux or macOS https://aka.ms/workloadskippackagevalidation .
Updated advertising manifest microsoft.net.sdk.tvos.
Updated advertising manifest microsoft.net.sdk.android.
Updated advertising manifest microsoft.net.sdk.maui.
Updated advertising manifest microsoft.net.sdk.macos.
Updated advertising manifest microsoft.net.sdk.maccatalyst.
Updated advertising manifest microsoft.net.sdk.ios.
Updated advertising manifest microsoft.net.workload.mono.toolchain.
Installing workload manifest microsoft.net.sdk.tvos version 15.0.100-ci.upload-download-dotnettests.46.
Installing workload manifest microsoft.net.sdk.android version 30.0.100-preview.6.51.
Installing workload manifest microsoft.net.sdk.maui version 6.0.100-preview.6.874+sha.28d1f1d25-azdo.4904039.
Installing workload manifest microsoft.net.sdk.macos version 12.0.100-ci.upload-download-dotnettests.46.
Installing workload manifest microsoft.net.sdk.maccatalyst version 15.0.100-ci.upload-download-dotnettests.46.
Installing workload manifest microsoft.net.sdk.ios version 15.0.100-ci.upload-download-dotnettests.46.
Installing workload manifest microsoft.net.workload.mono.toolchain version 6.0.0-preview.7.21323.3.
Installing pack Microsoft.NET.Runtime.WebAssembly.Sdk version 6.0.0-preview.7.21323.3...
Writing workload pack installation record for Microsoft.NET.Runtime.WebAssembly.Sdk version 6.0.0-preview.7.21323.3...
Installing pack Microsoft.NETCore.App.Runtime.Mono.browser-wasm version 6.0.0-preview.7.21323.3...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.Mono.browser-wasm version 6.0.0-preview.7.21323.3...
Installing pack Microsoft.NETCore.App.Runtime.AOT.Cross.browser-wasm version 6.0.0-preview.7.21323.3...
Workload installation failed, rolling back installed packs...
Installing workload manifest microsoft.net.sdk.tvos version 14.5.100-ci.main.723.
Installation roll back failed: Failed to install manifest microsoft.net.sdk.tvos version 14.5.100-ci.main.723: The transaction has aborted..
Rolling back pack Microsoft.NET.Runtime.WebAssembly.Sdk installation...
Uninstalling workload pack Microsoft.NET.Runtime.WebAssembly.Sdk version 6.0.0-preview.7.21323.3.
Rolling back pack Microsoft.NETCore.App.Runtime.Mono.browser-wasm installation...
Uninstalling workload pack Microsoft.NETCore.App.Runtime.Mono.browser-wasm version 6.0.0-preview.7.21323.3.
Rolling back pack Microsoft.NETCore.App.Runtime.AOT.Cross.browser-wasm installation...
Workload installation failed: chmod: /tmp/Microsoft.NETCore.App.Runtime.AOT.Cross.browser-wasm-6.0.0-preview.7.21323.3-extracted/tools/opt: No such file or directory

install
  Install a workload.

Usage:
  dotnet [options] workload install [<WORKLOAD_ID>...]

Arguments:
  <WORKLOAD_ID>  The NuGet Package Id of the workload to install.

Options:
  --sdk-version <VERSION>                                                  The version of the SDK.
  --configfile <FILE>                                                      The NuGet configuration file to use.
  --add-source <SOURCE>                                                    Add an additional NuGet package source to use during installation.
  --skip-manifest-update                                                   Skip updating the workload manifests.
  --from-cache <from-cache>                                                Complete the operation from cache (offline).
  --download-to-cache <download-to-cache>                                  Download packages needed to install a workload to a folder which can be used for offline installation.
  --include-previews                                                       Allow prerelease workload manifests.
  --temp-dir <temp-dir>                                                    Configure the temporary directory used for this command (must be secure).
  --disable-parallel                                                       Prevent restoring multiple projects in parallel.
  --ignore-failed-sources                                                  Treat package source failures as warnings.
  --no-cache                                                               Do not cache packages and http requests.
  --interactive                                                            Allows the command to stop and wait for user input or action (for example to complete authentication).
  -v, --verbosity <d|detailed|diag|diagnostic|m|minimal|n|normal|q|quiet>  Set the MSBuild verbosity level. Allowed values are q[uiet], m[inimal], n[ormal], d[etailed], and diag[nostic].
  -?, -h, --help                                                           Show help and usage information

cc @steveisok @directhex

Author: lewing
Assignees: -
Labels:

arch-wasm, area-Build-mono

Milestone: -

@dotnet-issue-labeler dotnet-issue-labeler bot added the untriaged New issue has not been triaged by the area owner label Jun 23, 2021
@lewing lewing removed the untriaged New issue has not been triaged by the area owner label Jun 23, 2021
@lewing lewing added this to the 6.0.0 milestone Jun 23, 2021
@lewing
Copy link
Member Author

lewing commented Jun 23, 2021

found while testing #54342

steveisok pushed a commit to steveisok/runtime that referenced this issue Jun 24, 2021
We introduced Microsoft.NETCore.App.MonoCrossAOT.UnixFilePermissions.xml in dotnet#54501 to make sure the right permissions are set when installing AOT compiler workload packs.  We hardcoded the list to include mono-aot-cross, llc, and opt.  However, in wasm's case they only have mono-aot-cross.

This change makes the xml file a template and only includes mono-aot-cross for browser and all three for the other configurations.

Fixes dotnet#54612
@ghost ghost added the in-pr There is an active PR which will close this issue when it is merged label Jun 24, 2021
@lewing
Copy link
Member Author

lewing commented Jun 24, 2021

we will also need a check/fix in emsdk

@ghost ghost removed the in-pr There is an active PR which will close this issue when it is merged label Jun 24, 2021
lewing pushed a commit that referenced this issue Jun 24, 2021
* Fix MonoCrossAOT.UnixFilePermissions for wasm

We introduced Microsoft.NETCore.App.MonoCrossAOT.UnixFilePermissions.xml in #54501 to make sure the right permissions are set when installing AOT compiler workload packs.  We hardcoded the list to include mono-aot-cross, llc, and opt.  However, in wasm's case they only have mono-aot-cross.

This change makes the xml file a template and only includes mono-aot-cross for browser and all three for the other configurations.

Fixes #54612

* Use property instead of item for the file nodes

* Ankit suggestion

Co-authored-by: Steve Pfister <steve.pfister@microsoft.com>
@ghost ghost locked as resolved and limited conversation to collaborators Jul 25, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
arch-wasm WebAssembly architecture area-Build-mono
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant