Skip to content

dotnet10: not possible to run dotnet9 projects (can't find net core app 9) #464575

@gaelj

Description

@gaelj

Nixpkgs version

  • Unstable (25.11)

Describe the bug

Since I added dotnet 10 (SDK, runtime and aspnetcore) to my dotnet-combined package, I can run projects targeting dotnet 10. But if I try to run a project targetting dotnet 9, I get this error

You must install or update .NET to run this application.

App: /home/gaj/.nuget/packages/swashbuckle.aspnetcore.cli/9.0.6/tools/net9.0/any/dotnet-swagger.dll
Architecture: x64
Framework: 'Microsoft.NETCore.App', version '9.0.0' (x64)
.NET location: /nix/store/9pa71r5z5sw8z63x1ci4s08b9bj22cz5-dotnet-sdk-10.0.100/share/dotnet/

The following frameworks were found:
  10.0.0 at [/nix/store/9pa71r5z5sw8z63x1ci4s08b9bj22cz5-dotnet-sdk-10.0.100/share/dotnet/shared/Microsoft.NETCore.App]

My dotnet combined package is defined as

with pkgs.dotnetCorePackages;
    combinePackages [
      runtime_6_0-bin
      runtime_7_0-bin
      runtime_8_0-bin
      runtime_9_0-bin
      runtime_10_0-bin
      aspnetcore_6_0-bin
      aspnetcore_7_0-bin
      aspnetcore_8_0-bin
      aspnetcore_9_0-bin
      aspnetcore_10_0-bin
      #sdk_9_0-bin
      sdk_10_0-bin
      pkgs.openldap
  ]

Before upgrading to dotnet10, so, with dotnet 9 SDK, there was no problem running projects targetting older frameworks.

Steps to reproduce

Use the combined net core packages described above. Create a dotnet project targeting dotnet 9. Try to run the project.

Expected behaviour

The correct dotnet9 binary should be found and the project should run

Screenshots

No response

Relevant log output

Additional context

No response

System metadata

  • system: "x86_64-linux"
  • host os: Linux 6.17.8, NixOS, 25.11 (Xantusia), 25.11.20251122.1c69805
  • multi-user?: yes
  • sandbox: yes
  • version: nix-env (Nix) 2.31.2
  • nixpkgs: /nix/store/h1hadfn6kxjaan80vy4k78iwsnqhhd72-source

Notify maintainers

@corngood


Note for maintainers: Please tag this issue in your pull request description. (i.e. Resolves #ISSUE.)

I assert that this issue is relevant for Nixpkgs

Is this issue important to you?

Add a 👍 reaction to issues you find important.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions