FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

[release/9.0-staging] Fix case-insensitive JSON deserialization of enum member names by github-actions[bot] · Pull Request #112057 · dotnet/runtime · GitHub

Repository navigation

[release/9.0-staging] Fix case-insensitive JSON deserialization of enum member names - #112057

Merged
PranavSenthilnathan merged 4 commits into
release/9.0-stagingfrom
backport/pr-112028-to-release/9.0
Feb 19, 2025
Merged

PranavSenthilnathan merged 4 commits into
release/9.0-stagingfrom
backport/pr-112028-to-release/9.0

Conversation

github-actions Bot commented Jan 31, 2025 •
edited by jeffhandley
Loading

Copy link
Copy Markdown
Contributor

Backport of #112028 to release/9.0-staging

/cc @eiriktsarpalis @PranavSenthilnathan

Customer Impact

  • Customer reported
  • Found internally

When deserializing a string into an enum using a naming policy, if the C# enum member name is the same as its name derived from the naming policy, then the deserialization will be case sensitive. This prevents some values from being deserialized successfully in .NET 9.0 which previously worked fine in .NET 8.0. Reported in #110745.

Regression

  • Yes
  • No

Introduced in #105032.

Testing

User scenario was validated manually and new unit tests have been added to cover it.

Risk

Low. This is a targeted change that fixes the handling of a corner case that got regressed in .NET 9.

Copy link
Copy Markdown
Contributor

Tagging subscribers to this area: @dotnet/area-system-text-json, @gregsdennis
See info in area-owners.md if you want to be subscribed.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

jeffhandley left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Once the PR review is completed and the template is filled out, please apply the Servicing-consider Issue for next servicing release review label.

PranavSenthilnathan added the Servicing-consider Issue for next servicing release review label Feb 3, 2025
jeffhandley changed the base branch from release/9.0 to release/9.0-staging February 4, 2025 18:11

Copy link
Copy Markdown
Member

@PranavSenthilnathan / @eiriktsarpalis -- I overlooked that this backport had been queued up against release/9.0 instead of release/9.0-staging. I just re-targeted it.

jeffhandley changed the title [release/9.0] Fix case-insensitive JSON deserialization of enum member names [release/9.0-staging] Fix case-insensitive JSON deserialization of enum member names Feb 4, 2025
rbhanda added Servicing-approved Approved for servicing release and removed Servicing-consider Issue for next servicing release review labels Feb 4, 2025
rbhanda added this to the 9.0.3 milestone Feb 4, 2025
carlossanlop added Servicing-approved Approved for servicing release and removed Servicing-approved Approved for servicing release labels Feb 19, 2025
PranavSenthilnathan merged commit 33a0635 into release/9.0-staging Feb 19, 2025
PranavSenthilnathan deleted the backport/pr-112028-to-release/9.0 branch February 19, 2025 00:44
github-actions Bot locked and limited conversation to collaborators Mar 21, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-System.Text.Json Servicing-approved Approved for servicing release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants


Back | FazBrowse Home | New Git URL