docs(AGENTS): list port_ctl.py in Pillow/numpy tool exceptions (DOCS-AGENTS-PORT-CTL-DEP) #2551

Closed
leonida/mandy
kirigayakazima wants to merge 0 commits from fix/docs-agents-port-ctl-dep into main

Pull request closed

This pull request cannot be reopened because the branch was deleted.

kirigayakazima commented 2026-11-28 01:56:25 +00:00

DOCS-AGENTS-PORT-CTL-DEP. Claim.

scripts/port_ctl.py (added with the d3d12/ merge) imports PIL.Image inside shrink() with a standard-library fallback, so tests/test_docs_python_deps.py (test_agents_lists_the_tools_that_need_numpy_or_pillow) failed on main across check, stdlib-tests-linux, and macos-python.

This lists port_ctl.py alongside the other optional numpy/Pillow tools in AGENTS.md rather than weakening the AST import check.

Verification on Windows 11 (RTX 4070 Laptop host; stdlib/doc tests only, no game files or GPU execution tested):

  • Before fix (1a441d336): python -I tests/test_docs_python_deps.py failed with AssertionError: Lists differ: ['port_ctl.py'] != [].
  • After fix: python -I tests/test_docs_python_deps.py (3 tests, OK), python -I tests/test_docs_links.py (17 tests, OK), and python -I scripts/check_no_game_data.py AGENTS.md passed.

AI-assisted: Antigravity (Gemini).

DOCS-AGENTS-PORT-CTL-DEP. [Claim](https://github.com/ProjectLeonida/mandy/issues/1608#issuecomment-7231988112). `scripts/port_ctl.py` (added with the `d3d12/` merge) imports `PIL.Image` inside `shrink()` with a standard-library fallback, so `tests/test_docs_python_deps.py` (`test_agents_lists_the_tools_that_need_numpy_or_pillow`) failed on `main` across `check`, `stdlib-tests-linux`, and `macos-python`. This lists `port_ctl.py` alongside the other optional numpy/Pillow tools in `AGENTS.md` rather than weakening the AST import check. Verification on Windows 11 (RTX 4070 Laptop host; stdlib/doc tests only, no game files or GPU execution tested): - Before fix (`1a441d336`): `python -I tests/test_docs_python_deps.py` failed with `AssertionError: Lists differ: ['port_ctl.py'] != []`. - After fix: `python -I tests/test_docs_python_deps.py` (3 tests, OK), `python -I tests/test_docs_links.py` (17 tests, OK), and `python -I scripts/check_no_game_data.py AGENTS.md` passed. AI-assisted: Antigravity (Gemini).
zmasi commented 2026-11-28 03:02:31 +00:00

#2551 | head 33dbf34abe47f346078006250a55288a58165c95 (merged cleanly with main 02f71ccfe) | python -I tests/test_docs_python_deps.py | red on main: FAILED (failures=1) in 3 tests (['port_ctl.py'] != []) | green on PR+main: Ran 3 tests, OK | Windows 11, Python 3.12.10 | AI-assisted: yes

Diff reviewed (AGENTS.md only, adding port_ctl.py to the optional numpy/Pillow tools list). Also verified on merged PR+main: python -I tests/test_docs_links.py (17/17 OK), python -I tests/test_text_write_line_endings.py (3/3 OK), git diff --check, and scripts/check_no_game_data.py AGENTS.md (clean).

#2551 | head 33dbf34abe47f346078006250a55288a58165c95 (merged cleanly with main 02f71ccfe) | `python -I tests/test_docs_python_deps.py` | red on main: FAILED (failures=1) in 3 tests (`['port_ctl.py'] != []`) | green on PR+main: Ran 3 tests, OK | Windows 11, Python 3.12.10 | AI-assisted: yes Diff reviewed (`AGENTS.md` only, adding `port_ctl.py` to the optional numpy/Pillow tools list). Also verified on merged `PR+main`: `python -I tests/test_docs_links.py` (17/17 OK), `python -I tests/test_text_write_line_endings.py` (3/3 OK), `git diff --check`, and `scripts/check_no_game_data.py AGENTS.md` (clean).
aegish-zagi reviewed 2026-11-28 22:49:18 +00:00
aegish-zagi left a comment
No description provided.
Independent review (Linux, Python 3.12.3, AI-assisted) against current main adfb3821a — this PR's situation has changed since the earlier verification (which ran against main 02f71ccfe): - The PR is now CONFLICTING / merge state DIRTY against current main. - Current main already lists `port_ctl.py` in the AGENTS.md exceptions (line ~129, landed via e890d0a10 "docs: fix inaccurate doc paths/flags/env vars"): main's wording calls it a "control" tool and its fallback clause says the last two tools "fall back to the standard library when numpy is absent". - I checked `scripts/port_ctl.py` on main: it imports Pillow (`from PIL import Image`, for the capture-copy path) and I found no numpy import — so the one residual delta in this PR is the fallback wording ("when numpy or Pillow is absent"), which is arguably more accurate for port_ctl itself. Recommendation: rebase on current main; after the rebase the change reduces to that fallback-clause wording. If maintainers are fine with main's current sentence, this is superseded and can close; if the Pillow part of the fallback clause is wanted, a rebased one-line version is all that remains. No other files are touched and there is nothing else to fix in the change itself.
Sign in to join this conversation.
No description provided.