Repository navigation
Conversation
The problem bank is the largest hand-maintained asset in this repository —
1,022 index rows across eleven volumes — and nothing checked it. `links`
verifies that an anchor exists, not that it belongs to the row that cites it,
so the most common hand-editing mistake (a copied row whose anchor still
points at the previous problem) passed both `links` and `validate`:
| JSP-000038 | [Sendov conjecture](catalog-0001-0100.md#JSP-000039) | ... # accepted
`problems/README.md` also states several precise, machine-checkable facts about
itself, none of which were enforced: the total count, consecutive numbering,
volume boundaries, the eligibility rule, the claim-status lifecycle, and the
count of records carrying an `Attribution basis` row.
Add a `problems` command that asserts exactly those statements and nothing
more. The counts are read from the index prose rather than duplicated in the
script, so a curator who edits the claim is held to it:
- the `No.` column runs consecutively from JSP-000001 to the documented total;
- every row links its own anchor, in the volume that covers its number;
- the index title matches the catalog heading, and every record has a detail
table, an explicit anchor and a place in the index;
- `Eligible to claim` is `Yes` exactly when `Current status` is `Solved` and
`Lean proof` is `Yes`; `Pending verification` stays a screening judgement;
- `Claim status` is `Unavailable` unless the record is eligible, so the
documented `Unavailable -> Unclaimed -> Claimed` lifecycle holds;
- the index and the detail table agree on eligibility, status and Lean proof;
- the counts stated in the prose match the catalog.
The Lean proof rule follows the documented field shape: a status is stated
alone or extended with " — " and its sources. A qualification value is instead
reproduced with the wording the index states it preserves, which is why
`Reported; standalone source not located` and its fuller detail wording are
listed as a pair rather than loosening the rule for every record.
Running the new check against the current bank found one record that
contradicts itself. `JSP-000037` still carried the former "Yes" screening flag
in its `Lean proof` field — `. Yes —` — although the same record states in
`Eligibility scope` that "the former n≥3 entry carried a Yes screening flag.
That flag does not transfer to the combined unresolved entry or to dimension
two". Its index status was also `Progress (not fully resolved)`, the only
non-standard status word among 1,022 rows (417 `Progress`, 354 `Solved`,
250 `Open`); commit 727aff7, which capitalised the claim-status values, rewrote
all 1,026 index lines and missed this one. Both are corrected here. The
record's `Eligible to claim` stays `No`, so no screening outcome changes.
Validation (Windows, Python 3.13), with the JSP-000037 fix reverted to show the
check is load-bearing:
$ python scripts/manage.py problems # before the fix
ERROR: problems/README.md: JSP-000037 Current status must be one of Open, Solved, Progress
$ python scripts/manage.py problems # after the fix
problems: OK
$ python scripts/manage.py validate -> OK
$ python scripts/manage.py links -> OK
$ python scripts/manage.py build -> OK, no diff under data/
$ python scripts/manage.py check -> OK
$ python scripts/manage.py history --base f4e7173 -> OK
$ python -m unittest discover -s tests: 46 tests, 2 failures and 1 error
All 24 new problem-bank tests pass. The three failures are pre-existing
and unrelated to this change: two are the Windows path-separator defect
fixed in TheJustinSunPrize#608, and one needs symlink privileges the host does not grant
(CI runs on ubuntu-latest, where the suite is green).
`tests/test_problems.py` builds a small synthetic bank and asserts each rule
independently, including the two accepted shapes (credited detail status, and
the documented qualification wording) so the rules cannot silently tighten. A
final test applies the same check to the bank this repository actually
publishes, so the existing `python -m unittest discover -s tests` CI step fails
whenever the index and its catalogs drift apart. Enforcement therefore needs no
workflow change.
Author
|
Closing this PR myself. It no longer applies after #762 ("docs: simplify problem catalog status and presentation") reworked the same catalog/index surface this branch touches, so the merge conflict cannot be resolved into anything coherent without re-doing the work on a different basis. Per the current CONTRIBUTING.md guidance ("Use issues for other corrections or requests rather than changing unrelated repository files"), the still-open concern from this branch is tracked as issue #815 instead. No maintainer action needed here. |
6 of 7 tasks
7 of 8 tasks
8 of 9 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Change
The problem bank is the largest hand-maintained asset in this repository — 1,022 index rows across eleven volumes — and nothing checked it.
linksverifies that an anchor exists, not that it belongs to the row citing it. The most common hand-editing mistake, a copied row whose anchor still points at the previous problem, passed bothlinksandvalidate:problems/README.mdalso states several precise, machine-checkable facts about itself, none of which were enforced: the total count, consecutive numbering, volume boundaries, the eligibility rule, the claim-status lifecycle, and the number of records carrying anAttribution basisrow. Meanwhile the catalog is edited constantly — the last eleven commits are alldocs:changes to it — whilescripts/manage.pyhas not been touched since the initial commit.This adds a
problemscommand that asserts exactly those statements and nothing more. The counts are read from the index prose rather than duplicated in the script, so a curator who edits the claim is held to it:No.column runs consecutively from JSP-000001 to the documented total;Eligible to claimisYesexactly whenCurrent statusisSolvedandLean proofisYes;Pending verificationstays a screening judgement;Claim statusisUnavailableunless the record is eligible, so the documentedUnavailable → Unclaimed → Claimedlifecycle holds;The Lean proof rule follows the documented field shape: a status is stated alone or extended with
—and its sources, because the field "combines the proof status, source links, and formalization contributor credits". A qualification value is instead reproduced with the wording the index states it preserves, which is whyReported; standalone source not locatedand its fuller detail wording are listed as a pair rather than loosening the rule for every record.Enforcement needs no workflow change:
tests/test_problems.pyends with the same check applied to the bank this repository actually publishes, andpython -m unittest discover -s testsis already a step in theValidateworkflow, so index drift now fails CI on every push and PR. If you would rather see it as its own named step, adding one line to.github/workflows/validate.ymlis straightforward.Compatibility with the correction already in flight. Issue #569 / PR #574 propose reclassifying
JSP-000448:Eligible to claimfromPending verificationtoYes,Claim statusfromUnavailabletoUnclaimed, and the documented attribution count from 66 to 67. Running this check against the state PR #574 produces, with theJSP-000037correction from this PR applied, reportsproblems: OK— the check accepts that correction instead of blocking it. Two of the rules have the shape they do because of that record:Pending verificationis treated as a third legal value, and the index's short qualification wording is accepted alongside the catalog's fuller phrasing.Running the new check against the current bank found one record that contradicts itself.
JSP-000037still carried the former "Yes" screening flag in itsLean prooffield —. Yes —— although the same record states inEligibility scope:Its index status was also
Progress (not fully resolved), the only non-standard status word among 1,022 rows (Progress417,Solved354,Open250). Commit 727aff7, which capitalised the claim-status values, rewrote all 1,026 index lines and missed this one; the phrase itself came from a6ee64e. Both are corrected here.Evidence that the check is load-bearing — with the
JSP-000037correction reverted:Record or policy impact
JSP-000037is edited in two places: the index statusProgress (not fully resolved)becomesProgress, and the detailLean proofvalue loses the stale. Yes —marker. ItsEligible to claimstaysNoand itsClaim statusstaysUnavailable, so no screening outcome, nomination or award eligibility changes. The record's ownEligibility scoperow already states that the former flag does not transfer, so this aligns the field with the text beside it.No other record changes. The new check confirms that the remaining 1,021 rows already satisfy every rule, so this is a guard rail for future edits rather than a correction of current data. No schema, status transition or published decision changes.
Checks
python scripts/manage.py validateandpython scripts/manage.py linkspass.python scripts/manage.py buildhas run andpython scripts/manage.py checkpasses.Validation limits: all 24 new problem-bank tests pass. The three failures are pre-existing and unrelated to this change — two are the Windows path-separator defect fixed separately in #608 (
test_published_statement_immutable_and_superseded,test_revocation_keeps_original_evidence), and one (test_symlinks_and_misplaced_records_rejected) needs symlink privileges this host does not grant. CI runs onubuntu-latest, where the suite is green.buildleaves no diff underdata/.Reviewer decision