Skip to content

Native building project with Microsoft Identity included, failing on System.Net.Quic #74380

@Jaafar-abusair

Description

@Jaafar-abusair

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

Hi,

I have .net core 6.0 application, when I run it from visual studio, it run normally without any problem, when I do building it natively it's not working

I am using the following command, to build the project
dotnet publish -c Release -r win-x64

What I noticed, when I do normal build from VS2022, the System.Net.Quic version loaded to the build folder is 6.0.0.0, on native build, the app trying to load version 7.0.0.0

kindly check the image below, not sure if this is the right section for posting this.

image

Expected Behavior

Running the app in native mode

Steps To Reproduce

No response

Exceptions (if any)

System.TypeLoadException: Could not load type 'System.Net.Quic.Implementations.QuicImplementationProvider' from assembly 'System.Net.Quic, Version=7.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.
at identity.autofarmer.net!+0x8c7f79
at identity.autofarmer.net!+0x9465d5
at identity.autofarmer.net!+0x52f4ca
at identity.autofarmer.net!+0x2af272
at Microsoft.Extensions.Hosting.GenericHostBuilderExtensions.<>c__DisplayClass0_0.b__0(IWebHostBuilder) + 0x14
at identity.autofarmer.net!+0x729e1a
at identity.autofarmer.net!+0x2b0a33
at identity.autofarmer.net!+0x2b0685
at Program.

$(String[]) + 0x2b

.NET Version

6.0.302

Anything else?

ASP.NET Core version: 6.0
VS2022

.NET SDK (reflecting any global.json):
Version: 6.0.302
Commit: c857713418

Runtime Environment:
OS Name: Windows
OS Version: 10.0.22000
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\6.0.302\

global.json file:
Not found

Host:
Version: 6.0.7
Architecture: x64
Commit: 0ec02c8

.NET SDKs installed:
6.0.301 [C:\Program Files\dotnet\sdk]
6.0.302 [C:\Program Files\dotnet\sdk]

.NET runtimes installed:
Microsoft.AspNetCore.All 2.1.30 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.1.30 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.1.27 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 6.0.6 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 6.0.7 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 2.1.30 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.1.27 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 6.0.6 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 6.0.7 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 3.1.27 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 6.0.6 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 6.0.7 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-NativeAOT-coreclrquestionAnswer questions and provide assistance, not an issue with source code or documentation.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions