Commit Graph
17 Commits
Author SHA1 Message Date
Abdessamad Derraz a343be0da1 fix: validate_pr json says failed, not new
The JSON report put "outcome": "new" on every file without another
outcome, so a path that does not exist, or a file that failed a check,
was listed as a new contribution. A failed file now reads "failed".
2026-11-06 08:54:23 +01:00
Abdessamad Derraz f24b34c1ef feat: place recognised files with validate_pr
The report named the folder of each file and left the copy to the contributor, one file and one .variants/ name at a time. --place copies each recognised file from outside bios/ to its folder under the name the lists declare, or to the .variants/ slot of a name already held, never over a file. A hash with two names or two folders is not placed.
2026-11-05 19:25:47 +01:00
Abdessamad Derraz eaa7effa74 fix: mark held and unknown PR files for review
validate_pr said all checks passed for random bytes and for a copy of a held file, and sent the copy to the folder that already holds it. Each now reads REVIEW with its next step, the status line counts them, and a held copy gets no placement hint. A copy inside a tree kept out of dedup is still accepted.
2026-11-05 19:22:55 +01:00
Abdessamad Derraz b90f8bb0b9 chore: merge tooling batch 2026-11-05 15:57:19 +01:00
Abdessamad Derraz 3f07924faf fix: validate_pr reads each platform's own check
A file was matched by its container sha1 or md5 alone. A zipped_file
member, a Recalbox member digest, a RetroDECK sha256 and a RomM size and
crc32 are now read the way verify reads them, and an identical copy's
folder is where its variants go.
2026-11-05 11:51:56 +01:00
Abdessamad Derraz f285c32d67 feat: validate every file of a folder 2026-11-05 11:48:31 +01:00
Abdessamad Derraz 7b6b22351a fix: show no digest for a file never read 2026-11-05 11:48:31 +01:00
Abdessamad Derraz 36d93c1750 feat: name the folder of a profile-only file
validate_pr.py built its folder advice from platform lists alone, so a
file only an emulator profile declares got the generic
bios/Manufacturer/Console/ advice. Profiles now feed the same table
through each entry's system, and the contributing guide says the
command answers where a file goes.
2026-10-21 10:13:09 +02:00
Abdessamad Derraz 8d295273a5 fix: validate_pr checks the size a name expects
1024 bytes named scph5501.bin, a name every declaration sizes at 524288, were reported "File size OK" and offered a .variants slot at the repository root. The review now warns when no declaration of the name accepts the size, and places a variant beside the folder that holds the name.
2026-10-20 04:48:07 +02:00
Abdessamad Derraz 23a999153d fix: read PR hashes the way the resolver does
load_profile_hashes and load_platform_hashes read hash fields by hand: crc32 was never indexed and a comma list of sha256 stayed one key. A contribution a profile names by crc32 alone (clk's Electron os.rom, among 626 entries) or by one of mesence's four sha256 was reported as referenced nowhere. Both indexes now read through parse_hash_list, and a crc32 counts where no stronger hash is declared, bounded by the declared size.
2026-10-20 02:12:54 +02:00
Abdessamad Derraz 4231902a6c docs: write prose without dashes or semicolons
Profiles, the wiki, comments, docstrings, command output and schema descriptions carried em-dashes, clause-joining semicolons, unicode arrows, box-drawing banners and check-mark glyphs. Each sentence was rewritten rather than having its character swapped. Hashes, paths, source_ref values and every cited file:line are unchanged, which a comparison of each parsed profile against the previous revision confirms.

validate_pr comments now say PASS and FAIL in words, and source_ref values in a profile's structured blocks render as code. test_prose_style fails if any of these comes back, in tracked files or in the generated site.
2026-10-19 06:47:31 +02:00
Abdessamad Derraz 89073f26fe fix: tell a contributor where a BIOS goes 2026-10-18 16:30:46 +02:00
Abdessamad Derraz 61b37408f1 feat: name the folder a PR's BIOS belongs in 2026-10-18 08:44:41 +02:00
Abdessamad Derraz 7bd2579022 fix: stop calling a held file its own duplicate 2026-10-18 08:41:32 +02:00
Abdessamad Derraz 32d32e5718 fix: refuse validate_pr flags it would drop
Named files beside --changed were replaced by the git diff, and the
run reported no changed files about files it never read; --json
beside --markdown dropped the markdown. Both combinations are now
refused, and an empty JSON run prints an empty list.
2026-10-18 05:20:03 +02:00
Abdessamad Derraz 8d80ed9f90 feat: credit a pr file to the profiles that pin it 2026-10-17 12:45:40 +02:00
Abdessamad Derraz 0b5c534af4 fix: settle a contributed path before reading it
validate_pr.py inspects paths chosen by whoever opened the pull
request, and it hashed the file before deciding whether it was a
symlink. A link to /dev/zero was read until the job timed out, and a
link out of the checkout was hashed and reported as though its target
had been contributed. The shape is now settled first, and a test that
used to hang the run covers it.

The gate had no tests at all, and neither did the 3DS crypto reached
by dynamic import from validation.py: RSA PKCS#1 v1.5, AES-128-CBC and
ECDSA over GF(2^233), all written by hand. Coverage goes from 0 to 95%
on the curve, 0 to 55% on the gate, 9 to 35% on the rest. The curve
tests check against the published SEC 2 parameters rather than against
the module: the generator satisfies the curve equation and the group
order takes it to infinity.
2026-08-11 01:39:29 +02:00