-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Open
Labels
Description
Just a heads up
Summary
When running Ocelot unit and acceptance tests using dotnet-sdk-10.0.100-preview.7.25351.101, two tests fail, after investigation, it is caused by the breaking change dotnet/docs#46890 .If you'd like to work around this on your end, you can either handle null values in your code or update your configuration files to use empty strings instead of null, e.g.:
"ServiceName": ""
Details
- SDK: dotnet-sdk-10.0.100-preview.7.25351.101
- OS: Windows 11 24H2 x64
- Test Project: Ocelot.AcceptanceTests.dll
- Failing Tests:
Ocelot.AcceptanceTests.WebSocketTests.ShouldProxyWebsocketInputToDownstreamServiceAndUseLoadBalancer
Ocelot.AcceptanceTests.LoadBalancerTests.Should_load_balance_request_with_round_robin
Reproduction Steps
- Install only dotnet-sdk-10.0.100-preview.7.25351.101 and set
DOTNET_ROLL_FORWARD_ON_NO_CANDIDATE_FX=2
. - Update
Ocelot.AcceptanceTests.runtimeconfig.json
frameworks section to reference SDK 10.0.0-preview.7.25351.101. - Build and run the acceptance tests with
dotnet vstest Ocelot.AcceptanceTests.dll
. - Observe the two test failures described below.
Error Messages
it will will throw "System.ArgumentNullException: 'Value cannot be null. (Parameter 'key')'"
exception from source code.
Tests pass on:
- dotnet-sdk-8.0.411
- dotnet-sdk-10.0.100-preview.6.25326.107
- Fail on:
- dotnet-sdk-10.0.100-preview.7.25351.101
Additional Findings
- In previous SDK versions, the parameter passed to
TryScanNext()
inRoundRobin.cs
was an empty string. In preview 7 it is now null, causing theArgumentNullException
.
Please get details from dotnet/runtime#117316 .
raman-mraman-m