#!/bin/sh
# Q114 CHECK -- the free-tier audit must carry, for every row, a primary URL
# with a fetch date, an expiry cell and an eligibility verdict answering
# FREE-TIER-CANDIDATES.md's 2026-10-06 rule, and no "Verified" claim.
#
# rc 0 = every leg as expected; 1 = a graded fault; 2 = could not grade.
# The work is done by wizard-work/volt/q114_verify.py beside this file: it
# grades the committed document against the committed fetch transcript
# (q114-fetch-2026-10-31.tsv), then replays five seeded edits of a copy and
# requires each to red a named cell.  `--live` re-fetches every source URL and
# reports which digests moved; it is opt-in because a live re-read that did not
# happen must not read as a pass.
set -u
REPO="$(cd "$(dirname "$0")/../.." && pwd)" || exit 2
if ! cd "$REPO"; then
    echo "q114: could not grade -- cannot cd to $REPO"
    exit 2
fi
if ! command -v python3 >/dev/null 2>&1; then
    echo "q114: could not grade -- no python3 on PATH"
    exit 2
fi
exec python3 wizard-work/volt/q114_verify.py "$@"
