Avatar for the pydantic user
pydantic
pydantic-core
BlogDocsChangelog

replace ultra_strict with new union implementation

#867Merged
Comparing
dh/one-pass-unions-2
(
18f5fce
) with
main
(
0c46146
)
CodSpeed Performance Gauge
+1%
Untouched
140

Benchmarks

140 total
test_decimal_from_string_core
tests/benchmarks/test_micro_benchmarks.py::TestBenchmarkDecimal
CodSpeed Performance Gauge
+10%
42 µs38.2 µs
test_validate_literal[python-few_str_enum]
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+10%
20.8 µs18.9 µs
test_complete_core_lax
tests/benchmarks/test_complete_benchmark.py
CodSpeed Performance Gauge
+9%
425.6 µs389.9 µs
test_tuple_many_variable
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+7%
23.6 µs22.1 µs
test_validate_literal[json-few_mixed]
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+6%
22.4 µs21.1 µs
test_positional_tuple
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+6%
22.3 µs21.1 µs
test_chain_list
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+5%
29 µs27.5 µs
test_generator_python
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+5%
27.2 µs25.8 µs
test_tuple_many_positional
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+5%
22.3 µs21.3 µs
test_validate_literal[json-few_str_enum]
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+4%
24.6 µs23.6 µs
test_validate_literal[python-few_mixed]
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+4%
20.8 µs20 µs
test_core_str
tests/benchmarks/test_micro_benchmarks.py::TestBenchmarkUUID
CodSpeed Performance Gauge
+4%
42.6 µs41.1 µs
test_dont_raise_error_no_info
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+3%
18 µs17.4 µs
test_variable_tuple
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+3%
22.9 µs22.2 µs
test_with_default
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+3%
27.8 µs27 µs
test_core_model_py_extra
tests/benchmarks/test_serialization_micro.py
CodSpeed Performance Gauge
+3%
34.3 µs33.3 µs
test_model_instance_abc
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+3%
33.9 µs32.9 µs
test_date_from_date
tests/benchmarks/test_micro_benchmarks.py::TestBenchmarkDateX
CodSpeed Performance Gauge
+2%
14 µs13.7 µs
test_chain_two_functions
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+2%
31.2 µs30.6 µs
test_core_model_json_extra
tests/benchmarks/test_serialization_micro.py
CodSpeed Performance Gauge
+2%
34.6 µs33.9 µs
test_model_exclude_unset_true
tests/benchmarks/test_serialization_micro.py
CodSpeed Performance Gauge
+2%
38.7 µs38 µs
test_set_of_ints_core_json_duplicates
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+2%
860.3 µs843.3 µs
test_core_python
tests/benchmarks/test_micro_benchmarks.py::TestBenchmarkUUID
CodSpeed Performance Gauge
+2%
30.6 µs30 µs
test_frozenset_of_ints_duplicates_core
tests/benchmarks/test_micro_benchmarks.py
CodSpeed Performance Gauge
+2%
153.5 µs150.6 µs
test_core_future
tests/benchmarks/test_micro_benchmarks.py::TestBenchmarkDateX
CodSpeed Performance Gauge
+2%
22.1 µs21.7 µs

Commits

Click on a commit to change the comparison range
Base
main
0c46146
-17.12%
one shot smart unions using exactness
5df6ec1
2 years ago
by davidhewitt
+4.05%
add tests for egregious definiton + union cases
ac546ef
2 years ago
by davidhewitt
+13.77%
bin off Validator::complete
bab4c6d
2 years ago
by davidhewitt
-0.22%
Update src/input/input_python.rs
ba203f1
2 years ago
by davidhewitt
-0.56%
make some string coercions lax
186a40b
2 years ago
by davidhewitt
+12.41%
add v3 todo
436a0db
2 years ago
by davidhewitt
-11.8%
ensure model unions behave like main
bddf977
2 years ago
by davidhewitt
-19.91%
extend default test case
21fce4f
2 years ago
by davidhewitt
-0.06%
clarify some additional test cases against main
ac9ac78
2 years ago
by davidhewitt
+20.25%
compress smart union implementation
18f5fce
2 years ago
by davidhewitt
© 2026 CodSpeed Technology
Home Terms Privacy Docs