-
Notifications
You must be signed in to change notification settings - Fork 10.6k
UnmappedMemberHandling not working with Microsoft.AspNetCore.OpenApi #57981
Copy link
Copy link
Closed
Labels
Needs: Author FeedbackThe author of this issue needs to respond in order for us to continue investigating this issue.The author of this issue needs to respond in order for us to continue investigating this issue.area-minimalIncludes minimal APIs, endpoint filters, parameter binding, request delegate generator etcIncludes minimal APIs, endpoint filters, parameter binding, request delegate generator etcarea-mvcIncludes: MVC, Actions and Controllers, Localization, CORS, most templatesIncludes: MVC, Actions and Controllers, Localization, CORS, most templatesfeature-openapi
Milestone
Metadata
Metadata
Assignees
Labels
Needs: Author FeedbackThe author of this issue needs to respond in order for us to continue investigating this issue.The author of this issue needs to respond in order for us to continue investigating this issue.area-minimalIncludes minimal APIs, endpoint filters, parameter binding, request delegate generator etcIncludes minimal APIs, endpoint filters, parameter binding, request delegate generator etcarea-mvcIncludes: MVC, Actions and Controllers, Localization, CORS, most templatesIncludes: MVC, Actions and Controllers, Localization, CORS, most templatesfeature-openapi
Type
Fields
Give feedbackNo fields configured for issues without a type.
Is there an existing issue for this?
Describe the bug
In response to: #56318 (comment)
JsonUnmappedMemberHandling.Disallowdoes not seem to work.If I enable it for this object
I get
or an exception, depending on the way of configuration.
Expected Behavior
I expect to see
Steps To Reproduce
Exceptions (if any)
presumably because additional properties is expected to be an object, and not
False..NET Version
9.0.100-rc.1.24452.12
Anything else?
Something like the transformer below provides the expected behavior for my test cases