From 364e0506325d183f67769f1e2387022789e8ed29 Mon Sep 17 00:00:00 2001 From: Bryan Van Deusen Date: Wed, 23 Sep 2026 12:53:27 -0400 Subject: [PATCH] fix: a spliced-out test left its tail behind (4295) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Run 7366, in both the lint and unit lanes — one bug wearing two hats: NameError: name 'slots' is not defined tests/test_worker_lanes.py:278 Rewriting `test_worker_lane_check_constraints` — parametrised over (slots, cap, ok) — I cut the parametrize decorator and the assertion but left the two lines after it, which still referenced all three names. `ast.parse` is happy with that; only running it is not. Both failures were the same fragment, which is the tell: the lint lane's F821 and the unit lane's NameError are the same fact reported twice. Checked the rest of today's splices for the same seam rather than fixing only the one CI named — a module-level undefined-name sweep over all four test files I rewrote today comes back clean. Co-Authored-By: Claude Opus 5 (1M context) Claude-Session: https://claude.ai/code/session_01LVjrnpQjRgHdvq95rASoiR --- tests/test_worker_lanes.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/tests/test_worker_lanes.py b/tests/test_worker_lanes.py index 14be621..160a552 100644 --- a/tests/test_worker_lanes.py +++ b/tests/test_worker_lanes.py @@ -273,11 +273,6 @@ def test_the_row_carries_exactly_one_constraint_now(): for name in constraints: assert not name.startswith("ck_worker_lane_ck_"), f"doubled prefix: {name}" - # Evaluate the same predicates the database will, so the parametrize table - # documents what is accepted rather than restating the SQL. - satisfied = slots >= 0 and cap >= 0 and slots <= cap - assert satisfied is ok - # --- what an optional lane tells the operator before it is enabled -----------