-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Core: Deprecate Utils.get_options by July 31st, 2025 #4811
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Core: Deprecate Utils.get_options by July 31st, 2025 #4811
Conversation
|
@PoryGone (I noticed lx isn't a maintainer for SMW btw, idk if that's correct, feel free to ignore I just noticed it) FF1, Minecraft (kind of) and OoT are unmaintained, so that responsibility lies with core, although help is appreciated of course. :) |
|
Wargroove already has a PR to fix this here: https://github.com/ArchipelagoMW/Archipelago/pull/4764/files#diff-4d91617fe518a776ef29cfee1785d1ed26e99d9d424d3d9bbb926fd9484408b9R140 |
|
add to the list Adventure, BizHawk Client, Multiserver, SNIClient, factorio, and alttp because they use Utils.get_settings() which only exists because Utils.get_options needs to import settings.get_settings |
|
Looks like TLOZ uses the old method exactly once to find the filepath for our baserom (line 74 of Rom.py) @Rosalie-A knowing that you have the Z1 update out there, how do you wanna proceed with this? (looks like it would be on line 144 of Rom.py on your beta branch) |
Thanks for pointing that out. With it, we get a couple more pings. |
I'll just bundle this one into the update, since I'll be submitting that sometime in the near future. |
|
#4832 will update TLOZ to use the new API (along with everything else that PR does) |
|
Just double checked and #4448 no longer has |
|
FYI for tracking, MMBN3 got this fix added to #4575 based on review |
|
I don't see where this is being used in pokemon_rb |
looks like it was fixed in #4801 |
|
Oh nice, I missed that. Clicked the checkbox now :3 |
|
@t3hf1gm3nt Y'all have opened a PR, but it's in draft... I appreciate the effort, but obviously I can't really "count that". How close is that PR from being ready? @PoryGone DKC3 and SMW still have Utils.get_options ALTTP, BizhawkClient, and SNIClient also still need to remove their use of Utils.get_settings(). In case of BHC and SNIC, this is on core. In case of ALTTP, @Berserker66 |
|
If I missed something, let me know. I did a quick CTRL+Shift+F and saw that MMBN3 was actually fixed in an unrelated PR, yay :) But I still could have misidentified things. |
TBH I have no idea. Been mostly hands off of v2 outside the one test game I ran. That'd be a question for @Rosalie-A |
|
@Rosalie-A there is also a Utils.get_options() in your client. |
|
OptionsType = Settings # TODO: remove when removing get_options |
…upVi/Archipelago into 044_deprecation_getoptions
|
Merging start of next cycle |
The deprecation of
Utils.get_optionsis long overdue.Worlds can take the easy route and just switch to
settings.get_settings(), but in a lot of cases, there may also be a more proper way to use the new settings API.There is
MyWorld.settings(orself.settingsfrom inside a world instance), and also settings can be accessed via.setting_namenow, rather than["setting_name"]https://github.com/ArchipelagoMW/Archipelago/blob/main/docs/settings%20api.md
Proper migration to this API is encouraged to avoid another round of deprecation in the future.
Either way, worlds who still call
Utils.get_optionsmust switch over one way or another.From a quick "find usages" in PyCharm, these are the worlds using it:
Utils.get_options#5341Utils.get_options#5341Additionally, there are some worlds/places that do
Utils.get_settings(), which only works because Utils importssettings.get_settings(). These kinds of transitive imports are very much discouraged, so let's get rid of them here too.I would ask these maintainers of these worlds to open the appropriate PRs by July 31st.