Summary
ij's package doctests execute nowhere. [tool.pytest.ini_options] testpaths = ["tests"] wins over the run-tests-uv action's root-dir: ij input (which only feeds --cov=), and the action passes --doctest-modules with no path argument. So collection is scoped to tests/ and nothing under ij/ is ever doctested — locally or in CI — while CI reports green.
Fleet-level tracking of the mechanism: i2mint/wads#56.
What is actually broken behind that
Three distinct problems, all currently invisible:
LLMConverter.refine doctest raises NameError: name 'converter' is not defined — the example references a name it never defines.
ij/export/image.py doctest writes a real file into the repo root. It produced a stray diagram.png at the top level during investigation (removed). A doctest must not write into the working tree; it should use tmp_path/a temp dir, or be marked +SKIP.
- One doctest hangs indefinitely.
pytest ij --doctest-modules never terminates. The hanging example has not been isolated — that is the first task here.
Suggested approach
- Find the hanger first, since it blocks everything else. Bisect with
pytest ij --doctest-modules --collect-only to enumerate, then run modules one at a time with a timeout, e.g.:
for m in ij/**/*.py; do timeout 30 python -m pytest "$m" --doctest-modules -q || echo "SLOW/FAIL: $m"; done
Likely suspects are anything doing network I/O, subprocess rendering (mermaid/d2/plantuml CLI), or waiting on stdin.
- Fix (1) and (2), quarantine or fix (3).
- Only then widen
testpaths to include the package dir (e.g. testpaths = ["ij", "tests"]), so CI genuinely runs them. Verify with python -m pytest --collect-only -q before/after — the item count must go up.
- Mirror the CI invocation when checking, because wads CI force-overrides doctest flags and drops
NORMALIZE_WHITESPACE:
python -m pytest --doctest-modules -o doctest_optionflags='ELLIPSIS IGNORE_EXCEPTION_DETAIL' -q
Why it matters
ij's parser had a severe silent-data-loss bug (see #3) that survived precisely because coverage was thin and one passing test masked it. Package doctests are the main remaining unexercised surface.
Surfaced during the 2026-07-30 wave-0 rollout batch.
Summary
ij's package doctests execute nowhere.[tool.pytest.ini_options] testpaths = ["tests"]wins over therun-tests-uvaction'sroot-dir: ijinput (which only feeds--cov=), and the action passes--doctest-moduleswith no path argument. So collection is scoped totests/and nothing underij/is ever doctested — locally or in CI — while CI reports green.Fleet-level tracking of the mechanism: i2mint/wads#56.
What is actually broken behind that
Three distinct problems, all currently invisible:
LLMConverter.refinedoctest raisesNameError: name 'converter' is not defined— the example references a name it never defines.ij/export/image.pydoctest writes a real file into the repo root. It produced a straydiagram.pngat the top level during investigation (removed). A doctest must not write into the working tree; it should usetmp_path/a temp dir, or be marked+SKIP.pytest ij --doctest-modulesnever terminates. The hanging example has not been isolated — that is the first task here.Suggested approach
pytest ij --doctest-modules --collect-onlyto enumerate, then run modules one at a time with a timeout, e.g.:testpathsto include the package dir (e.g.testpaths = ["ij", "tests"]), so CI genuinely runs them. Verify withpython -m pytest --collect-only -qbefore/after — the item count must go up.NORMALIZE_WHITESPACE:python -m pytest --doctest-modules -o doctest_optionflags='ELLIPSIS IGNORE_EXCEPTION_DETAIL' -qWhy it matters
ij's parser had a severe silent-data-loss bug (see #3) that survived precisely because coverage was thin and one passing test masked it. Package doctests are the main remaining unexercised surface.Surfaced during the 2026-07-30 wave-0 rollout batch.