WUT_Computer_Science/.binary-allowlist
Krzysztof kuhy Rudnicki e512bde26f Gate the invariants, fix ECOTE's unrunnable tests, contain build output
Two invariants had been established by hand and left ungated, which is the
"a remedy that only works if someone remembers" pattern:

  - scripts/check_ignore_consistency.sh fails the commit if any TRACKED file
    is also gitignored. .binary-allowlist used to *instruct* the reader to
    re-run that check; now it is enforced. Verified both ways -- passes on the
    tree, and fails when an ignored file is force-added.

DOCS-runnability.md now really has two columns. Each environment writes only
its own gates/runnability-<env>.tsv and the doc renders from both, so a CI run
cannot clobber the local results. The ci tsv is gitignored: committing a copy
generated here would label this machine's capabilities as the runner's.
Rendering it surfaced a classic bug -- awk's NR==FNR idiom silently swallows
the SECOND file when the first is empty, so the table came out with a header
and no rows. It compares FILENAME instead.

runnability.yml deliberately does NOT diff against a committed baseline. A
status is a property of the machine, so `runnable` locally and `blocked` on a
runner is correct rather than drift, and diffing would make the workflow red
by construction. It fails on `error` instead -- a runner that crashes or
reports an unknown kind.

Then five more courses were actually run, because EADS alone had produced four
real bugs and one sample proves nothing:

  - ECOAR and EPFU build (nasm + 32-bit gcc, and gcc respectively).
  - ECOTE's 17 test modules could not run AT ALL. Its package is named `code/`,
    which shadows the standard library: pytest's debugging plugin imports pdb,
    pdb imports code, and it got this directory instead, so the suite died
    with an INTERNALERROR before collecting a single test. Renamed to
    translator/ with all 17 imports updated -- 26 tests now pass.
  - A LaTeX report builds. That one exposed a hazard rather than a bug:
    latexmk wrote its PDF beside the source, and in a course where the built
    name matches the submitted one it would have silently overwritten a
    tracked deliverable. Both the LaTeX and C++ runners now build into a
    gitignored build/, and rebuilding ECOGR leaves `git status` empty.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0172dj34FDpao6wsix8ZuCzE
2026-08-28 18:43:13 +02:00

74 lines
2.5 KiB
Plaintext

# Binary files this repo commits on purpose. One bash glob per line.
#
# Read by scripts/check_no_binaries.sh. Note that matching uses bash `case`,
# where `*` DOES cross `/` -- so `Programming/*.pdf` matches a .pdf at any
# depth under Programming/.
#
# Policy for this repo (approved decision 3). This is an archive of submitted
# university coursework: the reports, figures, schematics and datasets ARE the
# deliverable, so they stay, and history is not rewritten. What the gate is
# actually here to stop is NEW junk -- compiled output, and binaries dropped
# into the tooling directories.
#
# So the allowlist is scoped by PATH, not blanket:
# - documents/figures/data are allowed under Programming/ and NotProgramming/
# - compiled output (.o .so .a .exe .dll .dylib .class .pyc .pyo) is allowed
# NOWHERE, and has no entry below. 189 such files were untracked in
# d4075278; .gitignore keeps them out.
# - the repo root, gates/, scripts/ and .github/ have no entry either, so a
# binary added there is blocked.
#
# An allowlisted file that .gitignore ALSO matches fails silently on
# `git add` rather than erroring. That is enforced, not remembered: the
# ignore-consistency pre-commit hook (scripts/check_ignore_consistency.sh)
# fails the commit if any tracked file is gitignored.
# --- Reports and presentations (155 .pdf, 3 .docx, 1 .doc, 1 .pptx) ---------
Programming/*.pdf
NotProgramming/*.pdf
Programming/*.doc
NotProgramming/*.doc
Programming/*.docx
NotProgramming/*.docx
Programming/*.ppt
NotProgramming/*.ppt
Programming/*.pptx
NotProgramming/*.pptx
# --- Figures, screenshots, schematics (275 .png, 68 .jpg, 52 .gif, ...) -----
Programming/*.png
NotProgramming/*.png
Programming/*.jpg
NotProgramming/*.jpg
Programming/*.jpeg
NotProgramming/*.jpeg
Programming/*.gif
NotProgramming/*.gif
Programming/*.bmp
NotProgramming/*.bmp
Programming/*.svg
NotProgramming/*.svg
Programming/*.webp
NotProgramming/*.webp
Programming/*.ico
NotProgramming/*.ico
Programming/*.tif
NotProgramming/*.tif
Programming/*.tiff
NotProgramming/*.tiff
# --- Fonts shipped inside a submitted project ------------------------------
Programming/*.ttf
NotProgramming/*.ttf
# --- Datasets and course-supplied archives ---------------------------------
# The .tgz entries matter: EOPSY ships its simulators as ftp/sched.tgz and
# ftp/memory.tgz, and `make setup` extracts them. Blocking those would break
# the lab. The .zip files are submitted result bundles and course inputs.
Programming/*.zip
NotProgramming/*.zip
Programming/*.tgz
NotProgramming/*.tgz
Programming/*.bin
NotProgramming/*.bin