mirror of
https://github.com/kuhyx/steam-backlog-enforcer.git
synced 2026-11-12 08:30:48 +01:00
_remove_game_dirs deleted exactly one path at a time (the manifest's current installdir, app-id gated by callers), but a real incident showed that's not enough: an allowed game's install can end up split across naming variants (spaced display name vs. installdir vs. a typo'd variant), and any code path touching the wrong one risks destroying real files. Add a fuzzy name-match safety net inside _remove_game_dirs itself so it refuses to rmtree anything that plausibly names one of the currently-allowed games, tolerating case/spacing/punctuation, spelled-out numbers vs. digits vs. roman numerals, and minor typos -- independent of whatever app-id gating the caller already does. Extracted active_manual_picks/allowed_games/_pick_is_active out of _actions.py into a new leaf module (_allowed_games.py) so game_install.py can import allowed_games at the top level for this check without a circular import (_actions.py already imports from game_install.py for unrelated functions). _actions.py re-exports the two names other modules still import from it. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| docs | ||
| tests | ||
| __init__.py | ||
| _actions.py | ||
| _allowed_games.py | ||
| _cmd_done.py | ||
| _enforce_loop.py | ||
| _hltb_detail.py | ||
| _hltb_search.py | ||
| _hltb_types.py | ||
| _mcp.py | ||
| _scanning_confidence.py | ||
| _stats.py | ||
| _steam_state.py | ||
| _total_block.py | ||
| _web_dataset.py | ||
| _web_server.py | ||
| _whitelist.py | ||
| config.py | ||
| enforcer.py | ||
| game_install.py | ||
| hltb.py | ||
| library_hider.py | ||
| main.py | ||
| protondb.py | ||
| scanning.py | ||
| steam_api.py | ||
| store_blocker.py | ||