Repository navigation
Closed
Closed
Copy link
Labels
Known Build ErrorUse this to report build issues in the .NET Helix tabarea-System.Text.Jsonblocking-clean-ciBlocking PR or rolling runs of 'runtime' or 'runtime-extra-platforms'
Milestone
Description
Build Information
Build: https://dev.azure.com/dnceng-public/cbb18261-c48f-4abb-8651-8cdcb5474649/_build/results?buildId=714494
Build error leg or test failing: System.Text.Json.Nodes.Tests.JsonObjectTests.NullPropertyNameFail
Pull request: #102524
Error Message
C:\h\w\B0530946\w\A44C0927\e>xunit.console.exe System.Text.Json.Tests.dll -xml testResults.xml -nologo -nocolor -notrait category=IgnoreForCI -notrait category=OuterLoop -notrait category=failing
Discovering: System.Text.Json.Tests (app domain = on [no shadow copy], method display = ClassAndMethod, method display options = None)
Discovered: System.Text.Json.Tests (found 8549 of 8623 test cases)
Starting: System.Text.Json.Tests (parallel test collections = on [2 threads], stop on fail = off)
System.Text.Json.Nodes.Tests.JsonObjectTests.NullPropertyNameFail [FAIL]
Assert.Contains() Failure: Sub-string not found
String: "System.ArgumentNullException: Value canno"···
Not found: "propertyName"
Stack Trace:
/_/src/libraries/System.Text.Json/tests/System.Text.Json.Tests/JsonNode/JsonObjectTests.cs(110,0): at System.Text.Json.Nodes.Tests.JsonObjectTests.NullPropertyNameFail()
Finished: System.Text.Json.Tests
{
"ErrorMessage": "at System.Text.Json.Nodes.Tests.JsonObjectTests.NullPropertyNameFail()",
"ErrorPattern": "",
"BuildRetry": false,
"ExcludeConsoleLog": false
}
Known issue validation
Build: 🔎 https://dev.azure.com/dnceng-public/public/_build/results?buildId=714494
Error message validated: [at System.Text.Json.Nodes.Tests.JsonObjectTests.NullPropertyNameFail()]
Result validation: ✅ Known issue matched with the provided build.
Validation performed at: 6/22/2024 4:43:19 PM UTC
Report
Summary
| 24-Hour Hit Count | 7-Day Hit Count | 1-Month Count |
|---|---|---|
| 3 | 20 | 21 |
Metadata
Metadata
Assignees
Labels
Known Build ErrorUse this to report build issues in the .NET Helix tabarea-System.Text.Jsonblocking-clean-ciBlocking PR or rolling runs of 'runtime' or 'runtime-extra-platforms'
Activity
dotnet-policy-service commentedon Jun 20, 2024
Tagging subscribers to this area: @dotnet/area-system-text-json, @gregsdennis
See info in area-owners.md if you want to be subscribed.
eiriktsarpalis commentedon Jun 20, 2024
Duplicate of #103715? I just merged a fix for that in #103733.
eiriktsarpalis commentedon Jun 21, 2024
Going to keep open until the hit counts falls back to zero.
v-wenyuxu commentedon Jun 24, 2024
Failed in: runtime-coreclr libraries-pgo 20240622.1
Failed tests:
Error message:
Stack trace:
More failures
v-wenyuxu commentedon Jun 25, 2024
Failed in: runtime-coreclr libraries-jitstress 20240624.1
Failed tests:
Error message:
Stack trace:
More failures
JulieLeeMSFT commentedon Jun 25, 2024
eiriktsarpalis this test is still failing in our test pipelines as reported by v-wenyuxu above and in our intenal SPMI collection pepieline (failed on 6/23), which is limiting JIT team's test capability (runtime-coreclr superpmi-collect pipeline). Could you please take a look again?
eiriktsarpalis commentedon Jun 25, 2024
@JulieLeeMSFT I'm seeing the 24 hour hit counts drop. Given that this was only fixed a few days back I would assume this is because of PR branches that haven't been rebased on top of the latest main.
v-wenyuxu commentedon Jun 26, 2024
Failed in: runtime-coreclr libraries-jitstress 20240625.1
Failed tests:
Error message:
Stack trace:
More failures
eiriktsarpalis commentedon Jun 26, 2024
@v-wenyuxu could you share the commit hashes of the impacted builds? We need to validate that it incorporates d9b9676
jakobbotsch commentedon Jun 26, 2024
Here is an example run from 4 hours ago on main that has the failure: https://dev.azure.com/dnceng-public/public/_build/results?buildId=720735&view=results. Commit hash is eb29166.
jakobbotsch commentedon Jun 26, 2024
FWIW it seems to be JIT optimization sensitive, so it may be a JIT bug. The repro seems to require
DOTNET_TieredCompilation=0. I'm trying to bisect to the specific method that must be compiled with JIT optimizations enabled for the issue to occur.jakobbotsch commentedon Jun 26, 2024
The method is just the lambda right above the failing assertion, but I see no issue there. It just throws a
new ArgumentNullException("key")that seems to look fine. I'm trying to bisect to the commit where the test started failing.eiriktsarpalis commentedon Jun 26, 2024
It's pretty clear to me that this was introduced by #103645, however I don't entirely understand why the failure is platform sensitive. I followed up with 91c9d3c but apparently this isn't fixing the problem either?
jakobbotsch commentedon Jun 26, 2024
There is definitely something odd going on given that it stops reproducing with
DOTNET_TieredCompilation=1. It seems like somehow we are ending up with the string"propertyName"turning into the string"key"instead.jakobbotsch commentedon Jun 26, 2024
The indexer here:
runtime/src/libraries/System.Text.Json/tests/System.Text.Json.Tests/JsonNode/JsonObjectTests.cs
Lines 110 to 111 in a95e718
Resolves to the indexer on
JsonNodehere:runtime/src/libraries/System.Text.Json/src/System/Text/Json/Nodes/JsonNode.cs
Lines 236 to 246 in a95e718
This in turn directly calls
JsonObject.SetItem(string, JsonNode)here:runtime/src/libraries/System.Text.Json/src/System/Text/Json/Nodes/JsonObject.cs
Lines 237 to 253 in a95e718
That one doesn't seem to have the check to throw with
propertyNameas the argument name.It still doesn't explain why the test does not fail in debug mode, however.
eiriktsarpalis commentedon Jun 26, 2024
Let me try to debug the test locally and see why it passes.
jakobbotsch commentedon Jun 26, 2024
Ah, it passes because the stack trace contains frames with a parameter
propertyNamein it in debug. In optimized codegenex.ToString()looks something like:and the test fails. In unoptimized codegen
ex.ToString()looks like:and the test passes.
The
ex.ToString()should probably be replaced byex.Messagein the asserts?eiriktsarpalis commentedon Jun 26, 2024
Yes, I'll follow up with a PR.