-
-
Notifications
You must be signed in to change notification settings - Fork 32.8k
gh-137242: Change CI arguments: remove --randomize
, add --fail-rerun
#138303
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?
Conversation
--randomize
, add --fail-rerun
--randomize
, add --fail-rerun
It looks like some tests are already doing that on some runners. I'll switch this PR back to draft until this has been resolved. |
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 dislike changing CI defaults.
if ns.use_mp is None: | ||
ns.use_mp = 0 | ||
ns.randomize = True |
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 would prefer to keep randomization for --fast-ci and --slow-ci options.
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 would prefer adding an option to disable randomization, option which could be used with --fast-ci / --slow-ci.
ns.fail_env_changed = True | ||
if ns.python is None: | ||
ns.rerun = True | ||
ns.fail_rerun = True |
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.
You can already pass --fail-rerun. Making it the default would make all CIs way more strict, I dislike this idea. When I tried a few years ago, I discovered tons of flaky tests and it was a pain to fix all of them.
--randomize
can discover real problems, but they're often ordering dependencies between tests, which are difficult to diagnose, and usually have nothing to do with the PR on which they occur.I assume this was the reason for removing
--fail-rerun
from the--fast-ci
and--slow-ci
arguments in #110849. However, this renders--randomize
almost useless, because the failing test will usually pass on the rerun in a fresh process, and nobody will ever know that there was a failure.Also,
--rerun
without--fail-rerun
means that a test which ALWAYS fails the first time and passes the second time will still be treated as a pass. This seems unsafe.So I propose removing
--randomize
and restoring--fail-rerun
.This will also allow iOS and Android to switch to
--fast-ci
on GitHub Actions and--slow-ci
on the buildbots. They were previously unable to do this because of the frequent failures caused by--randomize
, which were not hidden on the rerun because these platforms use--single-process
mode.