Commit Graph

1026 Commits

Author SHA1 Message Date
Fabian Dill
cad217af19 Core: update cert file daily in customserver.py (#4454) 2025-04-06 05:31:14 +02:00
Benjamin S Wolf
ec75793ac3 Core: Add spoiler-only output mode (#4059)
* Core: Add spoiler-only output mode

* spoiler-only exceptions

* Move new errors to mystery_argparse
2025-04-05 09:50:52 -04:00
massimilianodelliubaldini
1bec68df4d WebHost: Standardize some 404 redirects (#4642) 2025-04-04 23:11:45 +02:00
Fabian Dill
dbaac47d1e Core: update various requirements (#4731) 2025-03-23 17:24:50 +01:00
NewSoupVi
b7fc96100c Revert "Core: update websockets (#4732)" (#4753)
This reverts commit 42eaeb92f0.
2025-03-19 01:39:18 +01:00
Fabian Dill
42eaeb92f0 Core: update websockets (#4732) 2025-03-16 22:13:12 +01:00
Scipio Wright
5d3d0c8625 WebHost: Update text for options you can't modify (#4614) 2025-03-15 07:10:07 -04:00
Scipio Wright
7e32feeea3 Webhost: Update random option wording on webhost (#4555)
* Update random option wording on webhost

* Update WebHostLib/templates/playerOptions/macros.html

Co-authored-by: Jouramie <16137441+Jouramie@users.noreply.github.com>
2025-03-15 07:09:04 -04:00
sgrunt
5662da6f7d Timespinner: Support new flags and settings from the randomizer (#4559)
* Timespinner: Add "no hell spiders" enemy rando option that is present in upstream settings

* Timespinner: Prism Break support tweaks (including tracker support)

* Timespinner: Add support for upstream Lock Key Amadeus flag

* Timespinner: Add support for upstream Risky Warps flag

* Timespinner: Add support for upstream Pyramid Start flag

* Timespinner: fix error in lab connectivity logic

* Timespinner: use has_all to simplify one check

Per PR suggestion.

Co-authored-by: Scipio Wright <scipiowright@gmail.com>

* Timespinner: fix apparent logic error inherited from in-rando logic

* Timespinner: adjust "Origins" location logic slightly further to account for a Risky Warps case

* Timespinner: remove the backward compat options for the recent flag additions

* Timespinner: add newly added Gate Keep option from rando

* Timespinner: adjust the laser access colours in the tracker

* Timespinner: fix an item description in the tracker

* Timespinner: based on testing feedback, put Laser Access items in their own category

* Timespinner: add support for new upstream flag Royal Roadblock

* Timespinner: also ensure the new flag gets put in slot data

* Timespinner: fix bug in universal tracker support indicating castle basement is accessible at the lower Rising Tides flooding level

* Timespinner: exclude Talaria Attachment and Timespinner Wheel from pyramid start starter progression items

* Timespinner: fix region logic for the left pyramid warp

* Timespinner: fix main Gyre access logic when Risky Warps warps you behind the lasers

* Timespinner: apply suggested spacing fix

Co-authored-by: Exempt-Medic <60412657+Exempt-Medic@users.noreply.github.com>

---------

Co-authored-by: sgrunt <sgrunt1987@gmail.com>
Co-authored-by: Scipio Wright <scipiowright@gmail.com>
2025-03-08 11:54:23 -05:00
black-sliver
8349774c5c customserver: ignore static datapackage optimization for old games (#4650) 2025-02-16 23:51:36 +01:00
Matthew Wells
c799531105 Docs: Add missing plural in faq (#4622) 2025-02-12 17:47:17 +01:00
Fabian Dill
39847c5502 WebHost: sort slots by player_id in api blueprint (#4354) 2025-01-20 02:05:07 +01:00
Fabian Dill
917335ec54 Core: it's 2025 (#4417) 2025-01-01 02:02:18 +01:00
qwint
8d9454ea3b Core: cast all the settings values so they don't try to get pickled later #4362 2024-12-12 21:36:56 +01:00
black-sliver
4a5ba756b6 WebHost: Set Generator memory limit to 4GiB (#4319)
* WebHost: Set Generator memory limit to 4GiB

* WebHost: make generator memory limit configurable, better naming

* Update WebHostLib/__init__.py

Co-authored-by: Fabian Dill <Berserker66@users.noreply.github.com>

* Update docs/webhost configuration sample.yaml

---------

Co-authored-by: Fabian Dill <Berserker66@users.noreply.github.com>
2024-12-10 02:44:41 +01:00
black-sliver
6c69f590cf WebHost: fix host room not updating (ports in) slot table (#4308) 2024-12-08 02:22:56 +01:00
Benjamin S Wolf
17b3ee6eaf Core: warn if a yaml is empty (#4117)
* Core: warn if a yaml is empty

* WebHost: ignore empty yaml

Generate: log which yaml documents are empty

* Actually remove empty yamls from weight_cache

* More verbose variable name

---------

Co-authored-by: NewSoupVi <57900059+NewSoupVi@users.noreply.github.com>
2024-12-01 05:18:00 +01:00
Fabian Dill
9eaca95277 WebHost: add a page to manage session cookie (#4173) 2024-11-30 04:11:28 +01:00
Fabian Dill
492e3a355e WebHost: delete unused script tag (#4062) 2024-11-30 00:37:26 +01:00
NewSoupVi
e1f16c6721 WebHost: Fix crash on advanced options when a Range option used "random" as its default (#4263) 2024-11-27 14:19:52 +01:00
Fabian Dill
334781e976 Core: purge py3.8 and py3.9 (#3973)
Co-authored-by: Remy Jette <remy@remyjette.com>
Co-authored-by: Jouramie <16137441+Jouramie@users.noreply.github.com>
Co-authored-by: Aaron Wagener <mmmcheese158@gmail.com>
2024-11-27 03:28:00 +01:00
Zach "Phar" Parks
5141f36e95 WebHost: Fix 500 server errors for hints involving ItemLink slots on tracker pages (#4198)
* Also makes adjustments to the style for these slots by italicizing its names (including multi-tracker).
* Player-specific trackers do not link to ItemLink player trackers (they do not exist).
* Fixes a bug on Factorio multi-tracker when item links exist.
2024-11-16 16:16:09 +00:00
black-sliver
f9c6ecc8b2 Webhost: fix doc and yaml filenames / install paths (#4193)
* WebHost: use new safe yaml template filename

this mirrors the change in ArchipelagoMW/#4106 in WebHost

* WebHost: install docs into safe filename and require docs to be named safe

* Test: update doc test for safe name

* WebHost: fix import order to not break ModuleUpdate
2024-11-15 17:31:03 +01:00
black-sliver
b3e5ef876a WebHost: update werkzeug (#4167) 2024-11-10 01:40:29 +01:00
black-sliver
345d5154a9 WebHost: fix missing timezone in tracker if-modified-since handling (#4125)
* WebHost: fix missing timezone in tracker if-modified-since handling

and add a test for it

* WebHost, Test: fix running test_tracker in parallel
2024-11-07 09:51:40 +01:00
black-sliver
f7b9ac990b WebHost: improve image asset loading performance (#4123)
* WebHost: Scale image assets

* WebHost: convert images to webp
2024-10-30 23:56:39 -04:00
Natalie Weizenbaum
579abb33c0 Properly fall back to a world's rich_text_options_doc (#4109)
Previously, because `default(..., true)` only checks if the
left-hand-side is falsey, not just `None`, this always forced options
to render in non-rich mode if they were explicitly set to
`rich_text_doc = None`. Now it matches the intended and documented
behavior, where `None` falls back to the world's
`rich_text_options_doc` setting.
2024-10-28 00:01:41 +01:00
black-sliver
5d4684f315 WebHost: restore fragment links for glossary and faq and make titles clickable (#4103)
* WebHost: restore fragment links for glossary and faq

such as /faq/en/#what-does-multi-game-mean

* WebHost: faq, glossary: make markdown titles clickable
2024-10-26 23:10:38 +02:00
black-sliver
f709d61d04 WebHost: optimize header-logo.svg (#4073)
* WebHost: reduce precision and optimize header-logo.svg

technically those files will not produce an identical output when rendered
however the difference is virtually impossible to see even when rendered to w=4096

* WebHost: keep original svg
2024-10-20 19:52:04 -04:00
black-sliver
c6d2971d67 WebHost: optimize WebHost theme PNGs (#4071)
using zopfli, saving 30%
2024-10-20 19:51:14 -04:00
Remy Jette
ede59ef5a1 WebHost: Fix NamedRange option dropdown being blank instead of custom when applying presets (#4063) 2024-10-17 18:40:46 +02:00
Fabian Dill
375b5796d9 WebHost: noscript faq and glossary (#4061) 2024-10-16 23:28:42 +02:00
black-sliver
6287bc27a6 WebHost: Fix too-many-players error not showing (#4033)
* WebHost: fix 'too many players' error not showing

* WebHost, Tests: add basic tests for generate endpoint

* WebHost: hopefully make CodeQL happy with MAX_ROLL redirect
2024-10-05 18:14:22 +02:00
Kory Dondzila
f06d4503d8 Adds link to other players' trackers in player hints. (#3569) 2024-09-23 17:21:03 -04:00
Mrks
8021b457b6 WebHost: Added Games Of A Seed To The User Content Page (#3585)
* Added contained games of a seed to the user content page as tooltip.

* Changed sort handling.

* Limited amount of shown games.

* Added missing dashes.

Co-authored-by: Kory Dondzila <kory.dondzila@atomicobject.com>

* Closing a-tags.

Co-authored-by: Kory Dondzila <kory.dondzila@atomicobject.com>

* Closing a-tags.

Co-authored-by: Kory Dondzila <kory.dondzila@atomicobject.com>

* Moved games list to table cell level.

Co-authored-by: Kory Dondzila <kory.dondzila@atomicobject.com>

* Moved games list to table cell level.

---------

Co-authored-by: Kory Dondzila <kory.dondzila@atomicobject.com>
2024-09-23 17:19:26 -04:00
black-sliver
710609fa60 WebHost: move api/room_status out of __init__.py (#3958)
* WebHost: move room_status out of __init__.py

The old location is unexpected and easy to miss.

* WebHost: fix typing in api/room_status
2024-09-18 10:27:53 +02:00
Fabian Dill
da781bb4ac Core: rename yaml_output to csv_output (#3955) 2024-09-18 04:37:10 +02:00
Aaron Wagener
69487661dd Core: change yaml_output to output a full csv (#3653)
* make yaml_output arg a bool instead of number

* make yaml_output dump all player options as csv

* it sorts by game so swap those columns

* capitalize game and name headers

* use a list and just add an if before adding instead of sorting

* skip options that the world doesn't want displayed

* check if the class is a subclass of Removed specifically instead of the none flag

* don't create empty rows

* add a header for every game option that isn't from the common ones even if they have the same name

* add to webhost gen args so it can still gen
2024-09-18 01:33:03 +02:00
black-sliver
f73c0d9894 WebHost: Better host room v2 (#3948)
* WebHost: add spinner to room command

and show error message if fetch fails due to NetworkError

* WebHost: don't update room log while tab is inactive

* WebHost: don't include log for automated requests

* WebHost: refresh room also for re-spinups

and do that from javascript

* Test, WebHost: send fake user-agent where required

* WebHost: remove wrong comment in host room
2024-09-18 00:47:26 +02:00
Aaron Wagener
430b71a092 Core: have webhost slot name links go through the launcher (#2779)
* Core: have webhost slot name links go through the launcher so that components can use them

* fix query handling, remove debug prints, and change mousover text for new behavior

* remove a missed debug and unused function

* filter room id to suuid since that's what everything else uses

* pass args to common client correctly

* add GUI to select which client to open

* remove args parsing and "require" components to parse it themselves

* support for messenger since it was basically already done

* use "proper" args argparsing and clean up uri handling

* use a timer and auto launch text client if no component is found

* change the timer to be a bit more appealing. also found a bug lmao

* don't hold 5 hostage and capitalize URI ig

---------

Co-authored-by: NewSoupVi <57900059+NewSoupVi@users.noreply.github.com>
2024-09-08 00:03:04 +02:00
Draexzhan
d802f9652a Webhost: Fixed typo in userContent.html #3896
Changed "no" to "not"
2024-09-06 20:40:21 +02:00
Danaël V.
f9fc6944d3 Docs: Removing #archipelago-dev from places (#3876)
* Cleaning up (#4)

Cleanup

* Changed channel name

* Changed channel name

* Update docs/world maintainer.md

* Update docs/world maintainer.md
2024-09-05 22:55:19 +02:00
black-sliver
2aa0653b6d WebHost: update dependencies (#3871) 2024-09-03 02:31:42 +02:00
black-sliver
73701292b5 Core, CI: Add Python 3.12 support (#3290)
* Core, CI: add py3.12 compat

* Stardew Valley: Fix tests for Py3.12

* ModuleUpdate: always install pkg_resources

* Docs: update supported python versions

* WebHost: update pony to upstream 0.7.18

* CI: test hosting update to py3.12

* Update docs/running from source.md
2024-09-02 10:08:16 +02:00
black-sliver
1a41e1acc8 customserver: fix memory leak (#3864) 2024-09-01 20:34:50 +02:00
Exempt-Medic
9fbaa6050f I have no idea (#3791) 2024-08-14 00:21:42 -04:00
Remy Jette
77e3f9fbef WebHost: Fix NamedRange values clamping to the range (#3613)
If a NamedRange has a `special_range_names` entry outside the
`range_start` and `range_end`, the HTML5 range input will clamp the
submitted value to the closest value in the range.

These means that, for example, Pokemon RB's "HM Compatibility" option's
"Vanilla (-1)" option would instead get posted as "0" rather than "-1".

This change updates NamedRange to behave like TextChoice, where the
select element has a `name` attribute matching the option, and there is
an additional element to be able to provide an option other than the
select element's choices.

This uses a different suffix of `-range` rather than `-custom` that
TextChoice uses. The reason is we need some way to decide whether to use
the custom value or the select value, and that method needs to work
without JavaScript. For TextChoice this is easy, if the custom field is
empty use the select element. For NamedRange this is more difficult as
the browser will always submit *something*. My choice was to only use
the value from the range if the select box is set to "custom". Since
this only happens with JS as "custom' is hidden, I made the range hidden
under no-JS. If it's preferred, I could make the select box hidden
instead. Let me know.

This PR also makes the `js-required` class set `display: none` with
`!important` as otherwise the class wouldn't work on any rule that
had `display: flex` with more specificity than a single class.
2024-07-29 20:13:44 -04:00
Scipio Wright
b273852512 Fix obvious typo (#3622) 2024-07-28 00:44:48 -04:00
black-sliver
948f50f35d customserver: fix minor memory leak (#3636)
Old code keeps ref to last started room's task and thus never fully cleans it up.
2024-07-14 13:56:56 +02:00
black-sliver
187f9dac94 customserver: preemtively run GC before starting room (#3637)
GC seems to be lazy.
2024-07-14 13:56:27 +02:00