Commit Graph
5515 Commits
Author SHA1 Message Date
Abdessamad Derraz 6b597f85a0 refactor: give each installer module one role
The split had pushed each helper down into the lowest module using it.
Names now sit with the concern they belong to (68 modules, 45 before),
each with a one-line docstring saying it, and the import graph stays
acyclic. Statement source and comments moved unchanged: every top-level
statement of install.py keeps an identical ast.dump.
2026-11-18 02:55:56 +01:00
Abdessamad Derraz 9b0c7a390c docs: word the installer build line for the site 2026-11-18 02:29:34 +01:00
Abdessamad Derraz e10c14935a docs: say install.py is built from installer/
The installer page, the tool list, the testing guide and the
architecture tree name the package, the build script and its check.
2026-11-18 01:37:38 +01:00
Abdessamad Derraz a98e0a7140 chore: check install.py against installer/ in CI
validate.yml and pr_checks.py run build_installer.py --check after the
lint, vermin holds installer/ to 3.8 beside install.py, mypy and ruff
read the package, and both workflows trigger on installer/**.
CONTRIBUTING says where installer changes go.
2026-11-18 01:37:33 +01:00
Abdessamad Derraz e9f6fe43a0 refactor: split the installer into a package
install.py held 31,575 lines and 1,370 definitions in one module. Its
source is now installer/, 45 modules by concern, each importing from the
others what it uses, so ruff and mypy read every module on its own.

scripts/build_installer.py joins them back into install.py in import
order, with one block of standard library imports and the zlib and
unicodedata guard. It refuses an import from outside the standard
library, a name two modules define, an import cycle, a renamed import
and an import-time read of a name from a later module. install.py stays
one stdlib-only file for the bootstraps, the launchers and PyPI.

The split was written by a script, statement by statement: every
top-level statement of the old file is in the new one with the same AST.
Two tests that located code by its neighbour now read it by name.
2026-11-18 01:37:28 +01:00
Abdessamad Derraz f75b87448e chore: weigh the astro 7.4.12 generator meta
Astro 7.4.12 writes its version in the generator meta of every page,
one byte longer than 7.4.4. AmberELEC ran 2 bytes over its budget on
Validation of 55e7616eb; each budget is now the size of its pages on
the site deployed from that commit.
2026-11-17 20:41:10 +01:00
Abdessamad Derraz 55e7616eb6 chore: upgrade astro to 7.4.12 2026-11-17 19:33:43 +01:00
Abdessamad Derraz 4981de59e1 chore: record branches whose work main holds
Each branch's work reached main through cherry-picks or later commits: the install.py region workers, the core info review, the jazz2-native and pom2 advances, the 2026-11-09 leftovers, the wanted page merge and the old gh-pages copy. This merge keeps main's tree unchanged and records them as merged.
2026-11-17 19:17:03 +01:00
Abdessamad Derraz 7895edd582 chore: drop type ignores mypy never reads 2026-11-17 16:44:35 +01:00
Abdessamad Derraz ecf225d007 refactor: read platform-only APIs without ignores 2026-11-17 16:44:35 +01:00
Abdessamad Derraz 6cbf1d9c74 refactor: keep result titles, fake menu by context 2026-11-17 16:31:25 +01:00
Abdessamad Derraz 14002da6b6 chore: merge the test suite noqa cleanup 2026-11-17 16:14:49 +01:00
Abdessamad Derraz 5f18caec31 refactor: put scripts/ on the test path once
tests/__init__ now puts the repository root and scripts/ on sys.path,
so no test module inserts them and every import sits in the import
block. ruff accepts the bare `import tests` the modules keep for its
side effects. The last suppressions go: helper test modules import as
tests.<name>, files open in with blocks, lambdas become functions.
2026-11-17 16:11:23 +01:00
Abdessamad Derraz aded24dbcc fix: read the split installer shapes in two tests 2026-11-17 15:44:44 +01:00
Abdessamad Derraz 8f1b88bb7e chore: lint with ruff in CI, drop mypy baseline
The code now carries no type error and no ruff finding. CI runs mypy
bare and ruff with the rule set of pyproject.toml; pr_checks.py and
the contribution guide list both. The baseline and its tooling go.
2026-11-17 15:28:11 +01:00
Abdessamad Derraz f1e5cb3f5f chore: pin the bootstraps to the split installer 2026-11-17 15:28:07 +01:00
Abdessamad Derraz 0d0ec442b3 chore: merge the installer quality work 2026-11-17 15:11:43 +01:00
Abdessamad Derraz 188f9393a3 refactor: group outcome, check and menu arguments 2026-11-17 14:02:33 +01:00
Abdessamad Derraz b2dd7a3483 refactor: pass the held files to check_lines 2026-11-17 13:56:23 +01:00
Abdessamad Derraz 578cf5f5f5 refactor: split _install by stage 2026-11-17 13:56:07 +01:00
Abdessamad Derraz af1ecce103 refactor: split _install by stage 2026-11-17 13:55:34 +01:00
Abdessamad Derraz be949319ba refactor: type decoded input as keys or mouse 2026-11-17 13:53:01 +01:00
Abdessamad Derraz 991564fbd6 refactor: run the full screen as a session 2026-11-17 13:51:58 +01:00
Abdessamad Derraz 8a06a2b547 refactor: split the plan, result and help screens 2026-11-17 13:51:58 +01:00
Abdessamad Derraz 93574ad11c refactor: split fetch_manifest, tighten types 2026-11-17 13:51:58 +01:00
Abdessamad Derraz 682953fbc6 refactor: split _validate_manifest by section 2026-11-17 13:51:58 +01:00
Abdessamad Derraz 0a3fa929c0 refactor: split detect_platforms by frontend 2026-11-17 13:51:58 +01:00
Abdessamad Derraz 0cfe8cd5c9 refactor: read msvcrt as the runtime holds it 2026-11-17 13:51:58 +01:00
Abdessamad Derraz cebbded40e refactor: run the full screen as a session 2026-11-17 13:51:31 +01:00
Abdessamad Derraz 0502ae52e7 refactor: split the plan, result and help screens 2026-11-17 13:51:27 +01:00
Abdessamad Derraz 056c81e9a3 refactor: split the tui rows, keys and taps
TuiState.__init__, tui_blocker, tui_rows, _activate, _option, _tui_key and tui_mouse split by screen and stage; TuiRow values narrowed where the action fixes their type.
2026-11-17 13:09:36 +01:00
Abdessamad Derraz 20464aa3f7 refactor: split removal planning by stage 2026-11-17 13:05:21 +01:00
Abdessamad Derraz 60587c1d90 refactor: split removal planning by stage 2026-11-17 13:05:03 +01:00
Abdessamad Derraz c4e6f01292 refactor: split main by check stage
main runs its option checks and its dispatch in named stages. The card
rules carry their BIOS folder as a str, the menu's drive number no longer
shares its name with the folder index, and SystemDrive is read under the
name Windows keys it by.
2026-11-17 12:20:07 +01:00
Abdessamad Derraz 646b5d9077 chore: sync the mypy baseline after the type fixes 2026-11-17 11:11:04 +01:00
Abdessamad Derraz a4fb158e15 refactor: keep the nt test of the partial lock 2026-11-17 11:10:01 +01:00
Abdessamad Derraz ee1755d7a4 refactor: read IO from the typing import line 2026-11-17 11:10:01 +01:00
Abdessamad Derraz 3bce66bea7 refactor: split the download and run end stages 2026-11-17 11:10:01 +01:00
Abdessamad Derraz 820dc311f2 refactor: split main by check stage
main runs its option checks and its dispatch in named stages. The card
rules carry their BIOS folder as a str, the menu's drive number no longer
shares its name with the folder index, and SystemDrive is read under the
name Windows keys it by.
2026-11-17 10:11:28 +01:00
Abdessamad Derraz 352094379b refactor: keep value semantics of copy records 2026-11-17 10:08:46 +01:00
Abdessamad Derraz 455babfe0f refactor: split plan_games and the pack helpers
plan_games, _plan_game_folder, _swap_in and _write_verified read by stage, _fill_pack takes its pack as one tuple, check_lines its folder reads as CheckHeld. LocalCopy, PackPart and Unreadable become plain classes: their index and count fields shadowed the tuple methods. Openers of ZIP members are typed IO[bytes].
2026-11-17 10:08:00 +01:00
Abdessamad Derraz c0594b3b11 refactor: split standalone copies and line menu
Stage helpers for the standalone folder install and copies, the line
menu's Enter line, keys and answers, the games document reads and the
game reader; type the menu choice, the card rows and the byte order.
2026-11-17 10:08:00 +01:00
Abdessamad Derraz 1c37f1eb02 refactor: split the wanted list build by stage 2026-11-17 10:01:23 +01:00
Abdessamad Derraz e14a7d79bb chore: merge the verify and truth quality work 2026-11-17 09:48:56 +01:00
Abdessamad Derraz 190b3ae5df refactor: split standalone copies and line menu
Stage helpers for the standalone folder install and copies, the line
menu's Enter line, keys and answers, the games document reads and the
game reader; type the menu choice, the card rows and the byte order.
2026-11-17 09:48:38 +01:00
Abdessamad Derraz 81a94fc267 refactor: make writable an instance method 2026-11-17 09:48:13 +01:00
Abdessamad Derraz bc50106587 refactor: take narrowing options as typed keywords 2026-11-17 09:48:13 +01:00
Abdessamad Derraz 04b3f4ebb2 fix: key the coverage cache on offline and assets
The coverage of a platform depends on what a release asset resolves
to: whether the run may download it and what .cache/large holds. A
test run (offline, its own cache) stored a result that the next normal
generate_site read back: Lakka at 534/535 instead of 535/535.
2026-11-17 09:38:21 +01:00
Abdessamad Derraz ec3a6ab8af refactor: render pages from a PageMeta in tests 2026-11-17 09:34:59 +01:00
Abdessamad Derraz c7d89627fb chore: merge the site generator quality work 2026-11-17 09:33:57 +01:00