astral-sh
ruff
BlogDocsChangelog

[ty] narrow tagged unions of `TypedDict`

#22104
Comparing
typeddict_union_narrowing
(
04ee4dc
) with
main
(
4745d15
)
CodSpeed Performance Gauge
+5%
Improvements
1
Untouched
8
Skipped
43

Benchmarks

Skipped (43)

Improved

pydantic
crates/ruff_benchmark/benches/ty_walltime.rs
CodSpeed Performance Gauge
+5%
10.8 s10.3 s

Passed

sympy
crates/ruff_benchmark/benches/ty_walltime.rs
CodSpeed Performance Gauge
+1%
51.3 s50.8 s
multithreaded
crates/ruff_benchmark/benches/ty_walltime.rs
CodSpeed Performance Gauge
+1%
1.4 s1.4 s
freqtrade
crates/ruff_benchmark/benches/ty_walltime.rs
CodSpeed Performance Gauge
+1%
8 s8 s
static_frame
crates/ruff_benchmark/benches/ty_walltime.rs
CodSpeed Performance Gauge
0%
20.4 s20.4 s
tanjun
crates/ruff_benchmark/benches/ty_walltime.rs
CodSpeed Performance Gauge
0%
2.5 s2.5 s
pandas
crates/ruff_benchmark/benches/ty_walltime.rs
CodSpeed Performance Gauge
0%
61.8 s61.9 s
altair
crates/ruff_benchmark/benches/ty_walltime.rs
CodSpeed Performance Gauge
-1%
5.1 s5.1 s
colour_science
crates/ruff_benchmark/benches/ty_walltime.rs
CodSpeed Performance Gauge
-1%
89.1 s89.9 s

Commits

Click on a commit to change the comparison range
Base
main
4745d15
-38%
Alex's edits
ae2d96f
11 hours ago
by oconnor663
+43.2%
different approach: synthesized *negated* typeddicts with possibly negated fields
04ee4dc
4 hours ago
by oconnor663
© 2025 CodSpeed Technology
Home Terms Privacy Docs