Commit f3b9f52
fix: add truncation awareness to loop output and warn on data loss
Address review feedback: the sliding window on allIterationOutputs
silently truncated the final loop output passed to downstream blocks.
- Track totalIterationCount on LoopScope so the true iteration count
is preserved even after pruning
- Include totalIterations and truncated flag in the loop block output
so downstream blocks can detect when data was pruned
- Log a warning with discarded/retained counts when truncation occurs
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent 1365a5f commit f3b9f52
2 files changed
+15
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
| 20 | + | |
19 | 21 | | |
20 | 22 | | |
21 | 23 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
248 | 248 | | |
249 | 249 | | |
250 | 250 | | |
| 251 | + | |
251 | 252 | | |
252 | 253 | | |
253 | 254 | | |
254 | 255 | | |
255 | 256 | | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
256 | 263 | | |
257 | 264 | | |
258 | 265 | | |
| |||
281 | 288 | | |
282 | 289 | | |
283 | 290 | | |
284 | | - | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
285 | 297 | | |
286 | 298 | | |
287 | 299 | | |
| |||
0 commit comments