-
Notifications
You must be signed in to change notification settings - Fork 222
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
Fix S6964 FP: Don't raise on properties annotated with the JsonRequiredAttribute #9275
Labels
Area: C#
C# rules related issues.
Sprint: Hardening
Fix FPs/FNs/improvements
Type: False Positive
Rule IS triggered when it shouldn't be.
Projects
Milestone
Comments
CristianAmbrosini
changed the title
Fix S6964 FP/FN: JsonRequired is not taken into account
Fix S6964 FP: JsonRequired is not taken into account
May 15, 2024
mary-georgiou-sonarsource
assigned mary-georgiou-sonarsource and unassigned mary-georgiou-sonarsource
May 15, 2024
Hello, @Hoffs! Thanks for reporting it. |
mary-georgiou-sonarsource
added
Area: C#
C# rules related issues.
Type: False Positive
Rule IS triggered when it shouldn't be.
labels
May 15, 2024
mary-georgiou-sonarsource
changed the title
Fix S6964 FP: JsonRequired is not taken into account
Fix S6964 FP: Don't raise on properties annotated with JsonRequired
May 15, 2024
mary-georgiou-sonarsource
changed the title
Fix S6964 FP: Don't raise on properties annotated with JsonRequired
Fix S6964 FP: Don't raise on properties annotated with the JsonRequiredAttribute
May 15, 2024
mary-georgiou-sonarsource
added a commit
that referenced
this issue
May 16, 2024
github-actions
bot
assigned mary-georgiou-sonarsource and unassigned zsolt-kolbay-sonarsource
May 21, 2024
github-actions
bot
assigned zsolt-kolbay-sonarsource and unassigned mary-georgiou-sonarsource
May 21, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Area: C#
C# rules related issues.
Sprint: Hardening
Fix FPs/FNs/improvements
Type: False Positive
Rule IS triggered when it shouldn't be.
Description
S6964 complains about "under-posting" when fields are not nullable, even though JsonRequired is specifically intended to avoid this issue.
Repro steps
Expected behavior
No issue reported.
Actual behavior
S6964 issue reported.
Known workarounds
Please provide a description of any known workarounds.
Related information
The text was updated successfully, but these errors were encountered: