Commit c29febf
Address PR #355 R11 P3: emit null instead of NaN in coverage artifact
The SDID coverage MC artifact carried bare ``NaN`` tokens for the
``stratified_survey`` × ``placebo`` / ``jackknife`` cells (unsupported
by design — strata/PSU/FPC raises at fit-time). Python's ``json``
module tolerates those tokens on read, but strict JSON parsers reject
them, making the committed artifact non-strict.
``_summarize`` now returns ``None`` (serializes as ``null``) instead
of ``float('nan')`` on the all-failed branch, and ``json.dump`` is
called with ``allow_nan=False`` so any stray non-finite value fails
loudly instead of serializing as a bare ``NaN`` / ``Infinity`` token.
The committed artifact has been patched in place (bare ``NaN`` →
``null``) and strict-loader-verified; no regen needed since the
numeric content on the previously-NaN cells was definitionally
absent.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 1a20c16 commit c29febf
2 files changed
Lines changed: 32 additions & 20 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
136 | 136 | | |
137 | 137 | | |
138 | 138 | | |
139 | | - | |
140 | | - | |
141 | | - | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
142 | 142 | | |
143 | | - | |
144 | | - | |
145 | | - | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
146 | 146 | | |
147 | 147 | | |
148 | 148 | | |
| |||
158 | 158 | | |
159 | 159 | | |
160 | 160 | | |
161 | | - | |
162 | | - | |
163 | | - | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
164 | 164 | | |
165 | | - | |
166 | | - | |
167 | | - | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
168 | 168 | | |
169 | 169 | | |
170 | 170 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
301 | 301 | | |
302 | 302 | | |
303 | 303 | | |
304 | | - | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
305 | 309 | | |
306 | 310 | | |
307 | 311 | | |
308 | 312 | | |
309 | 313 | | |
310 | | - | |
311 | | - | |
312 | | - | |
313 | | - | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
314 | 318 | | |
315 | 319 | | |
316 | 320 | | |
317 | 321 | | |
318 | 322 | | |
319 | 323 | | |
320 | | - | |
321 | | - | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
322 | 329 | | |
323 | 330 | | |
324 | 331 | | |
| |||
473 | 480 | | |
474 | 481 | | |
475 | 482 | | |
476 | | - | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
| 486 | + | |
| 487 | + | |
| 488 | + | |
477 | 489 | | |
478 | 490 | | |
479 | 491 | | |
| |||
0 commit comments