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

[Bug] Error with .NET 7: You must install .NET to run this application #3287

Closed
diegosasw opened this issue Nov 13, 2022 · 3 comments
Closed
Labels

Comments

@diegosasw
Copy link

I have installed .NET 7 and I don't have .NET 6 anymore. When installing the latest GitVersion and trying to run it with dotnet gitversion I get the following error

You must install .NET to run this application.

App: /home/diegosasw/.dotnet/tools/dotnet-gitversion
Architecture: x64
App host version: 7.0.0
.NET location: Not found

Learn about runtime installation:
https://aka.ms/dotnet/app-launch-failed

Download the .NET runtime:
https://aka.ms/dotnet-core-applaunch?missing_runtime=true&arch=x64&rid=ubuntu.22.04-x64&apphost_version=7.0.0

Expected Behavior

It should display the gitversion output

Actual Behavior

It's displaying the error stating that .NET location is Not found

Steps to Reproduce

Install .NET 7

sudo apt install curl
curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor | sudo dd of=/usr/share/keyrings/microsoft.gpg

For 22.04

echo 'deb [arch=amd64 signed-by=/usr/share/keyrings/microsoft.gpg] https://packages.microsoft.com/ubuntu/22.04/prod jammy main' | sudo tee /etc/apt/sources.list.d/microsoft.list >/dev/null

Install SDK and runtimes for .NET 7

sudo apt update
sudo apt install dotnet-sdk-7.0
sudo apt install dotnet-runtime-7.0 
sudo apt install aspnetcore-runtime-7.0

Validate dotnet is there

dotnet --version
7.0.100

Install GitVersion

dotnet tool install --global GitVersion.tool --version 5.11.1
Tool 'gitversion.tool' is already installed.

Now try to use it

dotnet gitversion
You must install .NET to run this application.

App: /home/diegosasw/.dotnet/tools/dotnet-gitversion
Architecture: x64
App host version: 7.0.0
.NET location: Not found

Learn about runtime installation:
https://aka.ms/dotnet/app-launch-failed

Download the .NET runtime:
https://aka.ms/dotnet-core-applaunch?missing_runtime=true&arch=x64&rid=ubuntu.22.04-x64&apphost_version=7.0.0

Context

Your Environment

  • Version Used: 5.11.1
  • Operating System and version (Windows 10, Ubuntu 18.04): Ubuntu 22.04
@diegosasw diegosasw added the bug label Nov 13, 2022
@diegosasw diegosasw changed the title [Bug] You must install .NET to run this application [Bug] Error with .NET 7: You must install .NET to run this application Nov 13, 2022
@diegosasw
Copy link
Author

diegosasw commented Nov 13, 2022

I suspect it's not yet fully supported although I can see support was merged already.
#3243

Using an environment variable

DOTNET_ROLL_FORWARD=Major

doesn't make any difference. No other versions installed.

@gep13
Copy link
Member

gep13 commented Nov 13, 2022

The PR that you linked to (#3243) is associated with this issue (#3169) which you will see is tagged on the 6.x milestone, which hasn't shipped yet.

@diegosasw
Copy link
Author

Oh I see, sorry and thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants