-
Notifications
You must be signed in to change notification settings - Fork 703
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
Zillion: use "new" settings api and cleaning #3903
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have not tested, but code looks good.
The PR title is a bit confusing though, out of the 58 changed lines only 1 happens to match the title :P
If you don't see a reason to merge it now, I think I'd wait for a decision on 3848 - I believe we want to merge that right after 0.5.1 is out and have worlds fail.
It says "and cleaning". |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One comment, everything else looks good code-wise. Did not test anything since the non-typing changes are very few and I am assuming you tested gen an item links.
worlds/zillion/__init__.py
Outdated
assert "players" in group | ||
group_players = group["players"] | ||
players_start_chars: List[Tuple[int, Chars]] = [] | ||
group_players = set(group["players"]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I has question: can a non-empty abstract set here be a frozenset?
If not, wouldn't an assert be better? You copy it and then assign it back, which seems fragile.
Alternatively group["players"] = group_players = set(group["players"])
would be an option?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, it did seem a little more fragile to separate those assignments.
I changed it to group["players"] = group_players = set(group["players"])
Even if the current code might not allow the frozenset
with items, that seems more like an implementation detail that I shouldn't rely on.
I generated a few seeds with item links and looked at spoilers after this change.
And I did test another playthrough after the more recent typing changes. |
What is this fixing or adding?
#3848 was the motivation for this,
but then I found a bunch of other stuff to clean up too.
@override
decoratorsLogging.warn
How was this tested?
played a game