Skip to content

Conversation

@Tatsh
Copy link
Contributor

@Tatsh Tatsh commented Aug 14, 2025

With the current code set to use exclude_none this excludes fields from the schema even if None is a valid option. That means a model field that is nullable cannot be set to None with a PATCH.

I am fairly certain you meant to put exclude_unset here.

@codecov-commenter
Copy link

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.04%. Comparing base (6a592c1) to head (4e5846e).
⚠️ Report is 13 commits behind head on master.
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #288      +/-   ##
==========================================
+ Coverage   98.01%   98.04%   +0.03%     
==========================================
  Files          68       68              
  Lines        2770     2813      +43     
==========================================
+ Hits         2715     2758      +43     
  Misses         55       55              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@eadwinCode
Copy link
Owner

With the current code set to use exclude_none this excludes fields from the schema even if None is a valid option. That means a model field that is nullable cannot be set to None with a PATCH.

I am fairly certain you meant to put exclude_unset here.

Yes. Thanks for the fix

@eadwinCode eadwinCode merged commit a9a6b60 into eadwinCode:master Aug 15, 2025
22 of 23 checks passed
@Tatsh Tatsh deleted the update-exclude-unset-not-none branch August 19, 2025 14:16
@Tatsh
Copy link
Contributor Author

Tatsh commented Aug 26, 2025

Hi could you make a new release with this fix? Thanks.

@oburla-centumd
Copy link

oburla-centumd commented Oct 16, 2025

Shouldn't we use exclude_unset on patch and keep update without any of those flags? Also waiting for the fix as this way ninja-extra is quite broken.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants