pydantic-core
pydantic-core copied to clipboard
add `validate_always` flag to validate default values
⚠️ WIP ⚠️
@samuelcolvin feedback welcome on this. IMO it will be useful in some usecases, in particular computed fields (I added a test to showcase this)
Codecov Report
Merging #230 (4d01dee) into main (6d431dc) will decrease coverage by
0.02%. The diff coverage is100.00%.
@@ Coverage Diff @@
## main #230 +/- ##
==========================================
- Coverage 98.69% 98.66% -0.03%
==========================================
Files 48 48
Lines 5042 5080 +38
Branches 35 35
==========================================
+ Hits 4976 5012 +36
- Misses 66 68 +2
| Impacted Files | Coverage Δ | |
|---|---|---|
| src/errors/kinds.rs | 99.15% <ø> (ø) |
|
| pydantic_core/_types.py | 100.00% <100.00%> (ø) |
|
| src/validators/typed_dict.rs | 98.96% <100.00%> (+0.06%) |
:arrow_up: |
| src/input/datetime.rs | 97.84% <0.00%> (-0.31%) |
:arrow_down: |
| src/input/input_python.rs | 98.40% <0.00%> (-0.27%) |
:arrow_down: |
| src/lookup_key.rs | 98.25% <0.00%> (-0.04%) |
:arrow_down: |
| src/validators/function.rs | 99.42% <0.00%> (-0.01%) |
:arrow_down: |
| src/input/mod.rs | 100.00% <0.00%> (ø) |
|
| ... and 2 more |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact),ø = not affected,? = missing dataPowered by Codecov. Last update 6d431dc...4d01dee. Read the comment docs.
replaced by #479