Skip to content

Commit 5f7e439

Browse files
author
pseusys
committed
strict zips
1 parent 20eb61b commit 5f7e439

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

evaluation/src/typhoon_eval/flow_plot.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ def _empty_dirs() -> dict:
314314
linewidth=0.3,
315315
width=0.8,
316316
)
317-
for x, h in zip(xs, heights):
317+
for x, h in zip(xs, heights, strict=True):
318318
bottoms[x] = bottoms.get(x, 0.0) + h
319319

320320

@@ -352,7 +352,7 @@ def _plot_all(
352352
def _empty_dirs() -> dict:
353353
return {"c2s": {c: 0 for c in _COMPONENTS}, "s2c": {c: 0 for c in _COMPONENTS}}
354354

355-
for ax, (c2s_addr, s2c_addr, buckets) in zip(axes_flat, pairs):
355+
for ax, (c2s_addr, s2c_addr, buckets) in zip(axes_flat, pairs, strict=True):
356356
values_by_dir: dict[str, dict] = {"c2s": {}, "s2c": {}}
357357
for t in times:
358358
dirs = buckets.get(t, _empty_dirs())
@@ -401,12 +401,12 @@ def _plot_all_per_packet(
401401

402402
component_patches, direction_patches = _make_legend()
403403

404-
for ax, (c2s_addr, s2c_addr, pair_records) in zip(axes_flat, pairs_with_records):
404+
for ax, (c2s_addr, s2c_addr, pair_records) in zip(axes_flat, pairs_with_records, strict=True):
405405
timestamps = [r["t"] for r in pair_records]
406406
xpos = _compute_xpos(timestamps)
407407

408408
values_by_dir: dict[str, dict] = {"c2s": {}, "s2c": {}}
409-
for xi, r in zip(xpos, pair_records):
409+
for xi, r in zip(xpos, pair_records, strict=True):
410410
direction = r.get("dir", "c2s")
411411
values_by_dir[direction][xi] = {comp: r.get(comp, 0) for comp in _COMPONENTS}
412412
# Ensure both directions have entries (empty dicts are fine for _draw_bars)

0 commit comments

Comments
 (0)