Closed daniellepintz closed 2 years ago
I don't think marking all as required is feasible given the number of tests we run and the overall process. Some reasons:
To me, the key is in investing resources to improving everything around the CI. Some ideas:
The community feels helpless when things fail because there is no resource for how our CI is structured on what are the goals of each job. They rely on us entirely.
But at this stage, setting all jobs as required would just make things worse.
If you or anybody from the community is motivated to improve the efficiency of all this, please reach out ❤️
@carmocca Going back to this, I must say I still believe the best thing to do is go through all our CI jobs, and make each one either required, or delete it. Otherwise, I feel we will always be fighting a never-ending battle against the CI, because as long as people are able to merge PRs with failing jobs, they will (not out of malice, just by nature of the system). Currently there are no real incentives for people to fix failing CI jobs.
To address your concerns:
Flaky tests can appear out of the blue (dependency update, bad network, environment change, bad caches, ...) which would block the full pipeline. They should be avoided at all costs but sometimes they just happen.
True. But in this case here are the scenarios I see:
GitHub doesn't allow restarting individual jobs.
True, but this is a pain point either way, and relatively minor.
Network errors are bound to happen if running enough jobs. Keep in mind that some tests download datasets so it's not just the initial request to run the job.
Then we should be running less jobs. If in the current state we already know some CI jobs are bound to fail, we are essentially resigning ourselves to a eternally-red CI, whether the jobs are required or not. We must fix this by deleting some jobs.
You raise good points, Danielle. My proposal would be to keep things as they are right now, fix existing broken tests (you are on this already!), reduce flakiness, etc. Then, as our confidence in the CI increases, we can start marking things as required.
Sounds great, I will continue working towards that!
I think CI is in a much better state right now compared to back in september 🤞. Ideally we would mark everything as required but there's still sources of flakiness around.
Closing this for now.
Agree we are in a better state! It is so nice to see the green checkmarks on PRs! Although there are still a few red X's we have to fix...
Motivation
Currently our CI is red on master, which has the following negative repercussions:
conda (3.7, 1.10)
CI job has been failing consistently on everyone's PRs for a while. A few days ago it only had 4 test failures, but now it has 30 - https://github.com/PyTorchLightning/pytorch-lightning/pull/9118/checks?check_run_id=3570542595. This is because whether 4 tests or 30 tests are failing for one CI "job" it appears the same on the checks on your PR, so people may merge a PR that causes test failures.Proposal
Make all CI jobs required for merging a PR. If we have a job running on a PR that is "okay" if it is failing, why have it at all? I propose we make all CI jobs required, and delete ones that we don't want to make required. This will also incentivize/force everyone to keep the CI green.
@PyTorchLightning/core-contributors