pytorch
f251bb40 - Cancel redundant GHA workflows (#54685)

Commit
5 years ago
Cancel redundant GHA workflows (#54685) Summary: This PR adds a lightweight workflow which runs when any of our GitHub Actions lint or test workflows start (currently just the three listed in the YAML in this PR's diff), and cancels redundant ones (e.g. if a PR author pushes several commits in rapid succession). Currently this isn't particularly impactful, but it would become more so if/when we add heavier workflows that run on PRs. Initially we tried using [`technote-space/auto-cancel-redundant-workflow`](https://github.com/technote-space/auto-cancel-redundant-workflow) instead of [`potiuk/cancel-workflow-runs`](https://github.com/potiuk/cancel-workflow-runs), but for some reason it the former doesn't seem to work even if triggered by `workflow_run` with the `TARGET_RUN_ID` input set appropriately. Pull Request resolved: https://github.com/pytorch/pytorch/pull/54685 Test Plan: janeyx99 and I tested this in a separate GitHub repo, and confirmed that it successfully cancels redundant `push`-triggered workflows on the source repo and `pull_request`-triggered workflows from forks. Reviewed By: janeyx99 Differential Revision: D27327999 Pulled By: samestep fbshipit-source-id: c5793a7660d21361381e0f033d314f2d603f70ec
Author
Parents
Loading