Actually swap option values for keyblade min an max to show correctly in spoiler log.
And clarify in the warning the two values get swapped. (same as bounties but not lucky emblems)
* MultiServer, customserver: move data package handling
Create a new class that handles conversion worlds+embedded -> context data.
Create a derived class that uses static_server_data+pony instead.
There is also a not very efficient feature to deduplicate strings (may need perf testing).
By moving code around, we can simplify a lot of the world loading.
Where code lines were touched, some typing and some reformatting was added.
The back compat for GetDataPackage without games was finally dropped.
This was done as a cleanup because the refactoring touched those lines anyway.
Also reworked the per-context dicts and the RoomInfo to hopefully be more efficient
by ignoring unused games. (Generating the list of used games was required for the new
code anyway.)
Side effect of the MultiServer cache: we now load worlds lazily (but still all at once)
and don't modify the games package in place. If needed we create copies.
This almost gets us to the point where MultiServer doesn't need worlds - it still needs
them for the forbidden items.
There is a bonus optimization that deduplicates strings in name_groups that may have bad
performance and may need some perf testing if we run into issues.
* MultiServer: fix string deduplication in data package cache
* MultiServer, customserver: minor formatting fixes
* MultiServer: fix data package cache for missing checksum case
* MultiServer: improve string deduplication in games package cache
* customserver: handle missing checksum in datapackage cache
* customserver: typing cleanup in games package cache
* Test, MultiServer, customser: add tests for games package cache
* Test, MultiServer: reorder imports
Hopefully this fixes the random test failures with pytest-xdist
* customserver: make WebHost import lazy in games package cache
and fix test
* customserver: games package cache: fix py3.11 compat
* MultiServer, customserver: cache: typing improvements
* customserver: cache: reformat
* Test: move customserver tests to not interfere with webhost
* MultiServer, customserver: cache: rename module
* Multiserver: better error message for missing Datapackage
* customserver: cache: invert if for readability
* customserver: optimize non_hintable_names
* Use an empty frozenset singleton
* Only include non-empty sets in static_server_data
* Only prefill dict with played games
This should save ~2-4KB per room and slightly speedup lookup.
---------
Co-authored-by: Fabian Dill <[email protected]>
This patch breaks up fill_restrictive to fill in batches of items at a time. Each batch creates its own batch_base_state, and additionally a sweep state created from the batch's base state (_partial_exploration_state). The advantage to this is that each maximum_exploration_state can be created from the batch's _partial_exploration_state, which has already reached many regions and locations, rather than having to sweep from base_state each time.
* Add check for cosmic terminal and use different arguments if so
* Changed check for terminal to be strictly against executable name instead of path
based on this comment https://github.com/ArchipelagoMW/Archipelago/pull/6436#discussion_r3994140550
* Add `ptyxis` to list of moddern terminals
Co-authored-by: Duck <[email protected]>
* Changed `-e` terminal launch method to use `sh`
This standardizes the environment in which archipelago components launch and fixes launching with `zutty`
* Properly import pathlib
* Added comment detailing what `modern_terminals` is
* Refactored launching in terminal to new function in utils
* Optimised imports in Launcher.py
* Revert "Refactored launching in terminal to new function in utils"
This reverts commit 43367987da.
* Fixed unintentional cleanup in Utils.py
* Simplify check for terminals
Co-authored-by: Duck <[email protected]>
* Fully import pathlib
* Fix spelling mistake
* added gnome-terminal to list of modern_terminals
* added cosmic-term and ptyxis as fallback terminals
* Changed terminal search to add more terminal names easier
also included `alacritty` and `kitty`
* Check xterm terminal last
Also stores the list of terminals in tuples
Co-authored-by: black-sliver <[email protected]>
* Add type hint to terminal variable
Co-authored-by: black-sliver <[email protected]>
---------
Co-authored-by: Osiris32-and-a-half <[email protected]>
Co-authored-by: Duck <[email protected]>
Co-authored-by: black-sliver <[email protected]>
* Correct Bounce Target logic, write unit tests
tmp
* that is not correct
* What was I smoking
* explicitly document None
* What was I smoking
* fix weakref syntax
* ruff
* fix magicmoc
* Address Berserker's comments
* comment
* consistently use self.assertEqual
* make slot 2 on team 3 not use deathlink to test different tags for the same slot on different teams
* Improve error message