tools/enrolment_check.sh: a crashing enrolment_edges.py is not reported as ABORTED (|| reads sort's status)

Open Beginner friendly
#2,305 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
62/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
python, shell
Domain
tooling

Research direction

The bug is in tools/enrolment_check.sh around line 110, where the pipeline python3 tools/enrolment_edges.py . | sort -u > "$EDGES" is followed by ||, which reads sort's exit status rather than the deriver's. Check how the script sets up pipefail or PIPESTATUS, then plant raise SystemExit(1) in tools/enrolment_edges.py main and run bash tools/enrolment_check.sh; echo rc=$?. Done means one ABORTED line naming the deriver and its status, a nonzero exit, a selftest case in tools/selftests.txt with its count pin updated, and unchanged counts on an unplanted run.

Written by the indexing model from the issue text.

Description

needs-triage

tools/enrolment_check.sh:110 runs

python3 tools/enrolment_edges.py . | sort -u > "$EDGES" || { ... ABORT ... }

without pipefail, so the || reads sort's status. If the deriver crashes (traceback, rc 1), sort still exits 0 on whatever partial output it got, and the gate does not report ABORTED: it surfaces only as a flood of has no suite invocation lines for every program, which reads as hundreds of enrolment failures rather than one broken tool.

Found while working on hq#58 (InauguralSystems/hq#58, branch claude/ci58-es-2a-fragments); not changed there because #1776 rewrites this file.

Repro (plant)

Insert raise SystemExit(1) (or 1/0) at the top of main in tools/enrolment_edges.py, then bash tools/enrolment_check.sh; echo rc=$? -> per-program "invoked by nothing" FAILs, no ABORT line naming the deriver.

Done when
  • With the deriver planted to crash, tools/enrolment_check.sh prints one ABORTED line naming tools/enrolment_edges.py and its exit status, and exits nonzero, with no per-program invocation lines.
  • tools/enrolment_check.sh --selftest carries that plant as a case (count pin in tools/selftests.txt updated in the same PR).
  • An unplanted run is unchanged (same examined/enrolled counts).

Generated by Claude Code

Dominant language
C
Stars
3
Forks
7
Avg merge
6h 21m
Merged PRs (30d)
323

Getting set up

Open in Codespaces

Starts the project's dev container in your browser, under your own GitHub account.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from InauguralSystems/EigenScript

All issues in InauguralSystems/EigenScript

Similar issues

More C issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.