-
Notifications
You must be signed in to change notification settings - Fork 7
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
Make wait for released wait for the version to be active #8717
base: master
Are you sure you want to change the base?
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.
LGTM, what's the purpose of this change ? Was this causing race conditions somewhere ?
tests/utils.py
Outdated
lookup = { | ||
int(v["version"]): v["status"] == "active" for v in versions.result["data"] | ||
} | ||
return lookup[int(version)] |
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 think cast is redundant
return lookup[int(version)] | |
return lookup[version] |
tests/utils.py
Outdated
lookup = { | ||
int(v["version"]): v["status"] == "active" for v in versions.result["data"] | ||
} | ||
return lookup[int(version)] |
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.
The previous implementation covered the case where version doesn't exist yet. This one doesn't.
lookup = { | |
int(v["version"]): v["status"] == "active" for v in versions.result["data"] | |
} | |
return lookup[int(version)] | |
return any(v["status"] == "active" for v in versions.result["data"] if int(v["version"]) == version) |
Description
Self Check:
Strike through any lines that are not applicable (
~~line~~
) then check the box