Skip to content

Kiota generate fails: You must install or update .NET to run this application #8002

Description

What are you generating using Kiota, clients or plugins?

Kiota plugin

In what context or format are you using Kiota?

Nuget tool

Client library/SDK language

None

Describe the bug

We have Kiota installed inside the container with .NET 10, but the kiota generate command fails with

You must install or update .NET to run this application.
App: /github/home/.dotnet/tools/kiota
Architecture: x64
Framework: 'Microsoft.NETCore.App', version '8.0.0' (x64)
.NET location: /usr/share/dotnet
The following frameworks were found:
  10.0.10 at [/usr/share/dotnet/shared/Microsoft.NETCore.App]
Learn more:
https://aka.ms/dotnet/app-launch-failed
To install missing framework, download:
https://aka.ms/dotnet-core-applaunch?framework=Microsoft.NETCore.App&framework_version=8.0.0&arch=x64&rid=linux-x64&os=ubuntu.24.04

Why? I thought that the latest Kiota will work with .NET 10 and doesn't require .NET 8 to be installed

Expected behavior

Can run the kiota generate command

How to reproduce

Create Docker container from dotnet/sdk:10.0 image.
Install and run Kiota

Open API description file

No response

Kiota Version

1.34.1

Latest Kiota version known to work for scenario above?(Not required)

No response

Known Workarounds

No response

Configuration

OS: Ubuntu 24.04
Docker container with the image dotnet/sdk:10.0

DOTNET_RUNNING_IN_CONTAINER=true
DOTNET_VERSION=10.0.10
ASPNET_VERSION=10.0.10
DOTNET_NOLOGO=true
DOTNET_SDK_VERSION=10.0.302
DOTNET_USE_POLLING_FILE_WATCHER=true
NUGET_XMLDOC_MODE=skip
POWERSHELL_DISTRIBUTION_CHANNEL=PSDocker-DotnetSDK-Ubuntu-24.04

Debug output

Click to expand log ```
</details>


### Other information

`dotnet tool list --global` returns

Package Id Version Commands

microsoft.openapi.kiota 1.34.1 kiota


`dotnet tool install --global Microsoft.OpenApi.Kiota --configfile nuget.config` returns

Tool 'microsoft.openapi.kiota' is already installed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    status:waiting-for-triageAn issue that is yet to be reviewed or assignedtype:bugA broken experience

    Type

    No type

    Projects

    Status
    Needs Triage 🔍

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions