Dump an model excluding `none` values
Open
feature
- Dominant language
- Python
- Stars
- 1.2k
- Forks
- 97
- PR merge metrics
- No merged PRs in 30d
Description
# Feature request
### Context
I don't want to waste database space writing empty data.
### Solution
Adding `exclude_none` paramater to `model_dump_doc` would solve the problem.
Contributor guide
Research direction
Start by locating the model_dump_doc entry point and inspect how its current parameters control document serialization. Add support for the requested exclude_none option, then verify that empty model values are omitted from the dumped document.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- mongodb, python
- Domain
- database
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100