Commit Graph
430 Commits
Author SHA1 Message Date
Abdessamad Derraz 2b5031ecd6 refactor: one owner per installer source decision
--emulator says its Narrowed line through detail, as every other narrowing. Detection records that it read the RetroArch configs, and a lookup detects again only before that, held by detection_held. The list and pack open apart from the --from folders, whose refusal one function builds for line mode and the full screen.
2026-11-22 02:26:45 +01:00
Abdessamad Derraz a51e6d3e3c docs: drop three clause semicolons 2026-11-22 01:25:24 +01:00
Abdessamad Derraz 352e2bbb5e refactor: take a recorded choice in one place
The journey to another device's folder no longer stops on Create the folder?: one missing level is created as line mode does, since the shared rule for a missing BIOS folder.
2026-11-22 01:06:40 +01:00
Abdessamad Derraz a9d94acdac fix: one full-drive remedy for plan and refusal
The line plan said to choose another folder, which line mode cannot do,
while the refusal after Enter named --dest. space_remedy now gives the
remedy to both, the screen keeping its folder row.
2026-11-22 00:58:06 +01:00
Abdessamad Derraz c4a129e200 fix: follow moved retrodeck folders under --dest
A run given --platform and --dest never detects, so retrodeck.json was
never read and a moved bios/ folder was ignored. MovedFolders looks the
root up on first use, is reset per run, and detection only warms it.
2026-11-22 00:58:06 +01:00
Abdessamad Derraz 9f3fc2e0c1 refactor: read offline from the screen state
The rows asked state.offline while the plan, the estimate and the
result read the environment, kept in step only by the session loop.
tui_offline_only(state) is the one question; the variable only carries
the choice to the runs and the wording.
2026-11-22 00:58:06 +01:00
Abdessamad Derraz af34c81d71 fix: one rule for a missing bios folder
The full screen asked Create the folder? for a single missing level,
which line mode creates, and focused Create for two, which line mode
asks with no as the answer. missing_folder() gives both modes the
nearest folder, the missing levels and the verdict.
2026-11-22 00:58:05 +01:00
Abdessamad Derraz 5c47fe57e0 chore: repin the installer after the merge 2026-11-21 21:46:53 +01:00
Abdessamad Derraz 11e3ebb44f fix: say why a removal stops in its events
A --file outside the folder printed its own line and returned 2 with no
removal_plan, and a removal or backup deletion with no yes, a folder that
is no backup and a setup left open ended on stderr alone. The first goes
through _removal_refused, the others raise Refusal.
2026-11-21 21:42:20 +01:00
Abdessamad Derraz 665e2ebb52 fix: send every refusal as an error event
--romm-firmware, --pack without a platform, an option the list does not
record, a board list the run cannot go on without, a full drive and the
--dest a named platform needs printed and exited on their own: --events
got end and no error. Each now raises Refusal where it is decided, and
refuse_name, --find and the space check stop formatting their own copy.
2026-11-21 21:42:20 +01:00
Abdessamad Derraz 571c4bbfd9 fix: count roms left out after the choice
The roms, configs and emulator folder lines were printed while the
entries were placed, before --system, --core, --region and the menu
narrowed the list: --system panasonic-3do on EmuDeck said 1918 roms
files were left out where 6 belong to the run. Placement now only
records the reason, and say_unplaced counts the narrowed entries
next to say_saves. The unused printing branch of place_save_entries
goes with it.
2026-11-21 21:42:20 +01:00
Abdessamad Derraz 6e0b0724de fix: hold the offline choice in the screen state 2026-11-21 21:42:19 +01:00
Abdessamad Derraz f0ab5181ab fix: keep the offline variable beside --offline 2026-11-21 21:42:19 +01:00
Abdessamad Derraz 0d82c50a63 chore: rebuild the installer after the merge 2026-11-21 19:51:33 +01:00
Abdessamad Derraz 8fc294ef97 fix: a full drive is an event, not stderr text 2026-11-21 19:51:02 +01:00
Abdessamad Derraz 0b0bf29089 fix: say why an unreadable board list stops a pack 2026-11-21 19:50:47 +01:00
Abdessamad Derraz c888ae8101 fix: keep stdout to events in a removal
--remove and --backups opened the --manifest and --from-pack before
the event stream started: the list's platform and the pack name went to
stdout ahead of start, and a refusal of the pack came with no event.
They are opened inside the action now.
2026-11-21 19:50:46 +01:00
Abdessamad Derraz eba627aa89 refactor: one refusal path to stderr and events
Library functions printed their refusal and exited, each deciding on its
own whether --events got an error event. --cores-dir, --installed-cores
with no core, a list without system_cores or standalone_builds, a pack
that cannot be used, a board list a run needs and --dest alone beside
two setups ended on code 1 with no reason in the stream.

They now raise Refusal (installer/refusal.py), carrying the stage, the
reason, the platform, the lines and the code. The install, an action
framed by events and main report it once: the error event, then the
same lines on stderr, so the text and exit codes stay as they were.
2026-11-21 19:50:46 +01:00
Abdessamad Derraz ced68a9135 fix: a removal drops the system name it recorded
The record keeps --system as typed (psx). Removing that system compared
the recorded name to the id, kept psx in the choice, and the next
update installed the PlayStation files again.
2026-11-21 19:50:46 +01:00
Abdessamad Derraz 80f42f0573 fix: one system name rule for install and remove
The removal resolved --system against the list's ids alone, so a
platform name or a site title that installed the files was refused as
an unknown system. Both paths now call resolve_systems.
2026-11-21 19:50:46 +01:00
Abdessamad Derraz 475dfe0e0a fix: quit, proxy and setup folder read once
A chosen quit is read from the state, so the version note after the
quit line no longer sends it to stdout where the launcher misses it.

The proxy the screen names is the one urllib uses for the list's URL
(scheme variable or system settings, NO_PROXY honoured), recorded in
the ListProblem when the request fails.

The setup screen and the plan format from facts read once (the BIOS
folder of each setup, the retroarch.cfg naming dest), never by a frame
in the thread that reads the keys.
2026-11-21 19:50:46 +01:00
Abdessamad Derraz 1593dfa85a docs: drop two clause semicolons 2026-11-21 16:59:28 +01:00
Abdessamad Derraz 5bfc9953e2 chore: repin the installer after the merge 2026-11-21 16:44:59 +01:00
Abdessamad Derraz 61a4e909bd fix: one space count for both plans and the run 2026-11-21 16:44:02 +01:00
Abdessamad Derraz 1e6f106525 refactor: one list failure for line and screen 2026-11-21 16:44:02 +01:00
Abdessamad Derraz 5436a45d4a fix: resolve the remote once, in main 2026-11-21 16:44:02 +01:00
Abdessamad Derraz 4cb82adce3 refactor: keep detection lines as data
Detection now keeps what it says in DETECTION_NOTES and prints it only in
line mode. The full screen reads the list under detection_held() instead
of capturing stdout and stderr and dropping refusals by comparing text,
which said a refusal twice once screen_text escaped its folder.
2026-11-21 16:44:02 +01:00
Abdessamad Derraz 36d5827b25 fix: read a full drive once when the run ends 2026-11-21 16:44:01 +01:00
Abdessamad Derraz 0e2be04f9c fix: read the folder screen drives once 2026-11-21 16:44:01 +01:00
Abdessamad Derraz f10fa21d17 docs: split clause semicolons in new comments 2026-11-21 06:45:11 +01:00
Abdessamad Derraz ec50bf6b41 fix: say why a local list beside --manifest fails
An oversized or unreadable standalone layout said "not valid: Expecting
value", and an unreadable target list read as absent, so the offline
run asked for the file already there. One reader of a capped local JSON
file now says the cause: unreadable, too large or not JSON.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz 8d2f71b026 fix: say why no list is found on the screen too
With RETROBIOS_REF on a tag that has no list, line mode named the
variable and the way out. The screen said only that there is no list at
this address, and gave no advice with the default revision either. Both
now read the same advice.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz 68378b4423 refactor: join names and date records in one place
Five sentences joined names by hand beside _names_and, the plan counted
"more systems" beside _plural, a record stamped its time beside
_record_now, and the record day and the backup day each formatted a
date. Each now calls the one helper.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz f412f7803d chore: keep two blank lines after part names 2026-11-21 06:04:39 +01:00
Abdessamad Derraz 8ecd102c77 refactor: name the listing options once
Eight places tested the five --list-* options by hand, and four lists
named them. One table and one function now say which a run gave, so a
sixth listing is one line.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz 9a27d0b574 refactor: name pack parts in one module
The part and marker names of a split pack were built and matched in
both the pack reader and the pack writer. The reader owns them now,
both patterns built from one.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz b338d94fa0 fix: record no narrowing axis for an older list
A list with cores and neither systems nor regions is from an older
release, and recorded_axes reads none from it. A pack built here or by
generate_pack wrote cores and regions in its manifest. The installer
pack now asks recorded_axes, and the builder follows the same rule.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz 7284a90a20 refactor: fold removal dests through one helper
Seven places in the removal compared a destination casefolded where the
drive folds case, three of them as closures of their own. One function
does it, so every comparison folds the same way.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz 8c74f3f0bc fix: read a typed folder the same in both modes
Line mode dropped quotes only when both ends had one, so a half-selected
paste made a folder whose name starts with a quote. The screen's reader
is now the only one: any quote at either end goes, variables expand
before ~.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz ee2e6e80ce refactor: list the copies of an entry in one place
Nine places listed an entry with its alternatives and slot choices by
hand. The known core names read only the alternatives, so a core named
by a slot choice alone would have counted as unknown.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz 7b89a558ff fix: ask folder questions through one reader
The copy question, the card question and the BIOS folder question each
read q, Enter, a listed number or a folder. With no drive listed, the
copy question took "2" as the folder ./2. They share one reader now,
and the y/N questions read only y or yes: "yeah" created folders.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz 1f215f1732 refactor: read mountinfo through one helper
The card checks and the FAT32 test each read /proc/self/mountinfo and
decoded its escaped mount point. One function reads the table and one
decodes a mount point.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz 2502d96734 refactor: count files read with one live counter
The check of files on disk and the read of a card's games each drew
their own "read N/M" line and progress events. Both use one counter
now, which only differs by its event kind and its noun.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz bf34e71804 fix: remove the games cache scratch on a failure
A cache write that failed left index.json.<pid>.part behind, one more
on each run. The cache and the install record now write through one
scratch file beside the target, removed when the write fails and named
when it cannot be.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz 5d0c2fd3c6 refactor: read retroarch.cfg values in one place
The Android launcher checks, the save folder rules and the UWP package
read retroarch.cfg with parsers of their own. They now share the one
that says an unreadable config once, and the UWP package expands its
~ as RetroArch does. The cores and info folders look up the config
beside a system folder through one function.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz 6acdf4b193 fix: retry archives and the app like files
One decision says whether a failed request is asked again and when:
5xx and 429 wait what Retry-After asks, a clock in the past or no certificate
list stops at once. A data archive and the handheld app waited 1 s on a
429 that asked for 30 and gave up where a BIOS file arrived, and the app
took a body cut short of its Content-Length as the file.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz c41fb9e609 fix: give data tree files the umask mode
Verified bytes reach their place through one helper that sets the mode a
plain open() gives and clears a read-only attribute. A data tree member
skipped both and landed 0600, unreadable by the emulator after a sudo
install. The expected digests of an entry are read by one function.
2026-11-21 06:04:39 +01:00
Abdessamad Derraz a92d81c385 fix: cap what a rolling data tree may write
A followed member is written up to twice its listed size plus 16 MiB,
and the whole tree up to twice its listed total plus 16 MiB: a source
serving gigabytes where the list records kilobytes fills no drive.
2026-11-19 09:05:41 +01:00
Abdessamad Derraz ff69210b18 feat: pin forge data trees, follow nightly ones
A data tree whose source names a revision is fetched at the commit its
branch points to and listed at that commit, whose bytes never change.
A source with no revision (the buildbot's nightly assets) is marked
rolling: the installer writes each listed file as the source serves it,
checked against its ZIP CRC-32, as RetroArch's own downloader does, and
the install record keeps it in place on the next run. The PPSSPP list
refused 49 of 169 files after each buildbot rebuild.
2026-11-19 08:59:42 +01:00
Abdessamad Derraz b688f41a5a docs: name the modules that replaced common.py
The wiki, the platforms README and two comments named common.py, and
the installer's region table named scripts/region.py. tools.md lists
core/, model/ and resolve/ where it listed common.py, and the testing
guide names test_layers. install.py is rebuilt from installer/ and its
pins rewritten.
2026-11-18 11:43:36 +01:00