AGENTS.md: the asset policy's size limit and exceptions, as the code has them #590

Open
qnjk wants to merge 1 commit from qnjk/Darner:agents-policy-numbers into Main
Contributor

Contributor role (optional)

  • Fluxer ID:

What it changes

  • The problem on main: the last bullet of AGENTS.md's Testing & QA said a file "over 640 KiB is refused" and that "the single exception in the tree is crates/darner-formats/src/bcpack-tables.bin". The checker disagrees on both counts: MAX_FILE_SIZE = 1024 * 1024 (1 MiB) at xtask/src/policy.rs:16, and EXCEPTIONS at :47 holds six entries — the BCPack tables, docs/darner-logo.png, apps/darner/darner.ico, crates/darner-loader/src/heap_sites/frame_users.rs and two more. The file reference was stale too: the allowed extensions are at :19-20, not :17-19.

    A contributor reading the rules would size a file to a limit that does not exist, and would not know about four of the six files that are allowed to exist (or, reading the other way, would think three of them were policy violations).

  • This change states the numbers the code has and points at EXCEPTIONS rather than naming one path. Documentation only.

How it was tested

  • Tested revision: 6773a40 (one commit on c8258f9).
  • cargo xtask policy — asset policy: 576 files ok (the checker is the authority for every number in the new sentence).
  • The three references were re-read in xtask/src/policy.rs: MAX_FILE_SIZE at :16, ALLOWED_EXTENSIONS at :19, EXCEPTIONS at :47, and the entries counted (6).
  • No crate, test or behaviour changes, so the three gates do not apply; no gameplay run.
  • Changes a default: no.
  • A/B result: not applicable — documentation only.

Checklist

  • Documentation only, so it needs no gameplay run.
  • This PR contains one change based on main.
  • The diff follows docs/asset-policy.md (cargo xtask policy: 576 files ok).
  • I recorded this PR's dependencies below.
    • Depends on: none

Checked for overlap

  • I searched the open pull requests for the same issue and for the files this touches.
  • Related PRs: #408 and #78 change AGENTS.md; neither changes this bullet in its description. No open or closed issue mentions the size limit or the exception count.
  • Replaces or overlaps: none found
## Contributor role (optional) - Fluxer ID: ## What it changes - The problem on main: the last bullet of `AGENTS.md`'s *Testing & QA* said a file "over 640 KiB is refused" and that "the single exception in the tree is `crates/darner-formats/src/bcpack-tables.bin`". The checker disagrees on both counts: `MAX_FILE_SIZE = 1024 * 1024` (1 MiB) at `xtask/src/policy.rs:16`, and `EXCEPTIONS` at `:47` holds **six** entries — the BCPack tables, `docs/darner-logo.png`, `apps/darner/darner.ico`, `crates/darner-loader/src/heap_sites/frame_users.rs` and two more. The file reference was stale too: the allowed extensions are at `:19-20`, not `:17-19`. A contributor reading the rules would size a file to a limit that does not exist, and would not know about four of the six files that are allowed to exist (or, reading the other way, would think three of them were policy violations). - This change states the numbers the code has and points at `EXCEPTIONS` rather than naming one path. Documentation only. ## How it was tested - Tested revision: `6773a40` (one commit on `c8258f9`). - `cargo xtask policy` — `asset policy: 576 files ok` (the checker is the authority for every number in the new sentence). - The three references were re-read in `xtask/src/policy.rs`: `MAX_FILE_SIZE` at :16, `ALLOWED_EXTENSIONS` at :19, `EXCEPTIONS` at :47, and the entries counted (6). - No crate, test or behaviour changes, so the three gates do not apply; no gameplay run. - Changes a default: no. - A/B result: not applicable — documentation only. ## Checklist - [x] Documentation only, so it needs no gameplay run. - [x] This PR contains one change based on `main`. - [x] The diff follows `docs/asset-policy.md` (`cargo xtask policy`: 576 files ok). - [x] I recorded this PR's dependencies below. - Depends on: none ## Checked for overlap - [x] I searched the open pull requests for the same issue and for the files this touches. - Related PRs: #408 and #78 change `AGENTS.md`; neither changes this bullet in its description. No open or closed issue mentions the size limit or the exception count. - Replaces or overlaps: none found
The line said "any file over 640 KiB is refused" and "the single exception
in the tree is crates/darner-formats/src/bcpack-tables.bin". The checker
has `MAX_FILE_SIZE = 1024 * 1024` — 1 MiB — at xtask/src/policy.rs:16, and
six entries in `EXCEPTIONS` at :47, the BCPack tables among them. The file
reference was stale too: the allowed extensions are at :19-20, not :17-19.

A contributor reading the rules would size a file to a limit that does not
exist and would not know four of the six files that are allowed to exist.
TrustNo1 changed title from [pr-docs] AGENTS.md: the asset policy's size limit and exceptions, as the code has them to AGENTS.md: the asset policy's size limit and exceptions, as the code has them 2026-12-06 03:26:48 +00:00
This pull request has changes conflicting with the target branch.
  • AGENTS.md
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u 'agents-policy-numbers:qnjk-agents-policy-numbers'
git switch 'qnjk-agents-policy-numbers'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'Main'
git merge --no-ff 'qnjk-agents-policy-numbers'
git switch 'qnjk-agents-policy-numbers'
git rebase 'Main'
git switch 'Main'
git merge --ff-only 'qnjk-agents-policy-numbers'
git switch 'qnjk-agents-policy-numbers'
git rebase 'Main'
git switch 'Main'
git merge --no-ff 'qnjk-agents-policy-numbers'
git switch 'Main'
git merge --squash 'qnjk-agents-policy-numbers'
git switch 'Main'
git merge --ff-only 'qnjk-agents-policy-numbers'
git switch 'Main'
git merge 'qnjk-agents-policy-numbers'
git push origin 'Main'
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
TrustNo1/Darner!590
No description provided.