-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Polymorphic JSON deserialization hangs indefinitely in native AOT since .NET 9 Preview 7 #108329
Comments
I couldn't figure out the best area label to add to this issue. If you have write-permissions please help me learn by adding exactly one area label. |
1 similar comment
I couldn't figure out the best area label to add to this issue. If you have write-permissions please help me learn by adding exactly one area label. |
Not sure if this belongs here or in the runtime repo. Please move as you see fit. |
Tagging subscribers to this area: @dotnet/area-system-text-json, @gregsdennis |
Sounds like a potential duplicate of #107740. Are you able to reproduce using the RC2 bits? |
Took some fiddling to figure out how to use RC2 but got it working. |
Describe the bug
When used in native AOT apps, System.Text.Json's polymorphic deserialization hangs the program indefinitely.
To Reproduce
Create project with
dotnet new console --aot
and use the following code:Then publish the app with
dotnet publish
and start the resulting executable.The program will hang before printing
result: ...
.Further technical details
Issue did not exist in .NET SDK 9.0.100-preview.6.24328.19.
Issue started appearing in .NET SDK 9.0.100-preview.7.24407.12 and persists in 9.0.100-rc.1.24452.12.
Issue can be observed on both Windows 10 and WSL2 (Ubuntu 22.04).
The text was updated successfully, but these errors were encountered: