Commit d2b2c41
fix(bench): refuse debug native builds before timing
tests/_native_guard.py rebuilds the cwd-local _interpreter.pyd via plain
`maturin develop` (debug) whenever src/*.rs is newer; the cwd package
shadows the venv release wheel, so a bench run after a Rust edit + pytest
silently timed a DEBUG engine -- engine rows inflated ~5x while
python/duckdb rows stayed sane (measured 2026-07-26).
The extension now exposes BUILD_PROFILE from cfg!(debug_assertions);
bench_serving exits with a rebuild hint unless it reads release, and
the native guard's rebuild message names the profile it builds.
Verified: debug build -> clear refusal (exit 1); release build -> normal
run; mise run gate-specializer green (129 cargo + 753 pytest).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>1 parent 1856658 commit d2b2c41
3 files changed
Lines changed: 34 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
28 | 30 | | |
29 | 31 | | |
30 | 32 | | |
| |||
140 | 142 | | |
141 | 143 | | |
142 | 144 | | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
143 | 163 | | |
144 | 164 | | |
145 | 165 | | |
| |||
192 | 212 | | |
193 | 213 | | |
194 | 214 | | |
| 215 | + | |
195 | 216 | | |
196 | 217 | | |
197 | 218 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
28 | 38 | | |
29 | 39 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
73 | 73 | | |
74 | 74 | | |
75 | 75 | | |
76 | | - | |
| 76 | + | |
| 77 | + | |
77 | 78 | | |
78 | 79 | | |
79 | 80 | | |
| |||
0 commit comments