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

Unable to find the .NET Runtime binary without explicitly configuring it (Windows) #404

Open
eduarddejong opened this issue Apr 29, 2024 · 1 comment
Assignees

Comments

@eduarddejong
Copy link

VS Code version:
1.88.1 (user setup)

Operation System and version:
Windows 11

Steps to reproduce

Launch VS Code with this extension enabled.

Expected behavior

This extension should automatically be able to find the installed .NET Runtime.
Especially because it's also configured in the Windows PATH environment variable.

Actual behavior

A popup with the following message appears on startup:

An error occurred while installing .NET (8.0): .NET Acquisition Failed: Validation of .dotnet installation for version 8.0.4~x64 failed: Expected installation folder c:\Users\<user profile dir>\AppData\Roaming\Code\User\globalStorage\ms-dotnettools.vscode-dotnet-runtime\.dotnet\8.0.4~x64 does not exist.

Within that same message box VS Code also gives me the option to manually configure the path, which is great nevertheless.
When I do that selects the path C:\Program Files\dotnet\dotnet.exe, which is correct and everything works fine.
It adds the following to my Settings.json:

"dotnetAcquisitionExtension.existingDotnetPath": [
    {
        "extensionId": "icsharpcode.ilspy-vscode",
        "path": "C:\\Program Files\\dotnet\\dotnet.exe"
    }
],

Alright, this works for now. But is this really needed?
I suspect this isn't intended and something goes wrong here.

ilspy-vscode extension logs

[14:38:01.053] Checking for .NET runtime 8.0
[14:38:05.283] Check finished, runtime path is: (not available)
[14:38:05.283] Checking for additional runtime dependencies (Linux only)
[14:38:05.283] Check for additional dependencies finished

@eduarddejong eduarddejong changed the title Unable to find the .NET Runtime binary without explicitly configuring it Unable to find the .NET Runtime binary without explicitly configuring it (Windows) Apr 29, 2024
@Rpinski Rpinski self-assigned this May 18, 2024
@Rpinski
Copy link
Member

Rpinski commented May 22, 2024

Sorry for the late response, but it looks like it's an issue with vscode-dotnet-runtime, which we use to detect and download .NET runtime. Such problems also appear with other extensions using it.

Those seem to be similar:

dotnet/vscode-dotnet-runtime#1684
dotnet/vscode-dotnet-runtime#1741

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

No branches or pull requests

2 participants