Skip to content

[dotnet-sdk-10.0.100-rc.2.25474.116] grandnode2 build get error: The call is ambiguous between the following methods or properties: 'JsonSerializer.Deserialize<TValue>(ReadOnlySpan<byte>, JsonSerializerOptions?)'... #51022

@Junjun-zhao

Description

@Junjun-zhao

Application Name: grandnode2
OS: Windows 10 22H2
CPU: X64
.NET Build Number: dotnet-sdk-10.0.100-rc.2.25474.116
App Source checking at: https://devdiv.visualstudio.com/DevDiv/_workitems/edit/2582392
Github Link: https://github.com/grandnode/grandnode2

Verify Scenarios
Windows10 22h2 x64 + dotnet-sdk-9.0.305: Pass
Windows10 22h2 x64 + dotnet-sdk-10.0.100-preview.7.25380.108: Pass
Windows10 22h2 x64 + dotnet-sdk-10.0.100-rc.1.25451.107: Fail
Windows10 22h2 x64 + dotnet-sdk-10.0.100-rc.2.25474.116: Fail

Description:

We build the third-party app with dotnet-sdk-10.0.100-rc.2.25474.116, it failed with error: The call is ambiguous between the following methods or properties: 'JsonSerializer.Deserialize<TValue>(ReadOnlySpan<byte>, JsonSerializerOptions?)' and 'JsonSerializer.Deserialize<TValue>(string, JsonSerializerOptions?)'.

Repro steps:

The machine needs to install dotnet-sdk-10.0.100-rc.2.25474.116

  1. Run command: "dotnet build" in \grandnode2\src\Core\Grand.Infrastructure.

Expected Result:

Build successfully.

Actual Result:
Build failed with error:

The call is ambiguous between the following methods or properties: 'JsonSerializer.Deserialize<TValue>(ReadOnlySpan<byte>, JsonSerializerOptions?)' and 'JsonSerializer.Deserialize<TValue>(string, JsonSerializerOptions?)'

Image

DotNet Info:

.NET SDK:
 Version:           10.0.100-rc.2.25474.116
 Commit:            54303ce0f4
 Workload version:  10.0.100-manifests.62cb6acc
 MSBuild version:   18.0.0-preview-25474-116+54303ce0f

Runtime Environment:
 OS Name:     Windows
 OS Version:  10.0.19045
 OS Platform: Windows
 RID:         win-x64
 Base Path:   C:\Program Files\dotnet\sdk\10.0.100-rc.2.25474.116\

Host:
  Version:      10.0.0-rc.2.25474.116
  Architecture: x64
  Commit:       54303ce0f4

.NET SDKs installed:
  10.0.100-rc.2.25474.116 [C:\Program Files\dotnet\sdk]

.NET runtimes installed:
  Microsoft.AspNetCore.App 10.0.0-rc.2.25474.116 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 10.0.0-rc.2.25474.116 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.WindowsDesktop.App 10.0.0-rc.2.25474.116 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]

@dotnet-actwx-bot @dotnet/compat

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions