Title: fixed #12325 - cancel workflows if a newer commit is pushed on the same branch by kitsiosk · Pull Request #7636 · cppcheck-opensource/cppcheck · GitHub
Open Graph Title: fixed #12325 - cancel workflows if a newer commit is pushed on the same branch by kitsiosk · Pull Request #7636 · cppcheck-opensource/cppcheck
X Title: fixed #12325 - cancel workflows if a newer commit is pushed on the same branch by kitsiosk · Pull Request #7636 · cppcheck-opensource/cppcheck
Description: Change Summary Currently, if a push to branchA triggers the CodeQL workflow, and shortly after a subsequent push on the same branchA triggers the CodeQL workflow, both runs will run. With these changes, the first run will be cancelled, thus saving compute resources (see below for quantity) without sacrificing functionality, since the second run will contain the changes from the first push as well. The introduced syntax comes from the official documentation. Context Hi, We are a team of researchers from University of Zurich and we are currently working on energy optimizations in Github Actions workflows. Based on our offline analysis, cancelling CodeQL runs triggered by a now-obsolete commit (because a new commit has triggered the CodeQL workflow again), could have saved ~49.9 CPU hours since the beginning of the project. For example, the commit 70b1f triggered this workflow run, and one minute later the commit ea2c3, that happened on top of the first commit, triggered this workflow. Both workflows ran till the end, spending ~12 CPU minutes each. With the proposed changes, the first run would be cancelled, hence saving ~11 CPU minutes and clearing the queue for other workflows. Kindly let us know (here or in the email below) if you would like more details on our offline evaluation, if you want to reject the proposed changes for other reasons, or if you have any question whatsoever. Best regards, Konstantinos Kitsios konstantinos.kitsios@uzh.ch
Open Graph Description: Change Summary Currently, if a push to branchA triggers the CodeQL workflow, and shortly after a subsequent push on the same branchA triggers the CodeQL workflow, both runs will run. With these cha...
X Description: Change Summary Currently, if a push to branchA triggers the CodeQL workflow, and shortly after a subsequent push on the same branchA triggers the CodeQL workflow, both runs will run. With these cha...
Opengraph URL: https://github.com/cppcheck-opensource/cppcheck/pull/7636
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:88bb59f2-ac1c-917d-1b49-153d7e165edf |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | 9732:1EC7:99A021:D4E777:6A4EF6B6 |
| html-safe-nonce | a8017c1baa44bb47123c04c5695e2739212dddb97fd359461710aaf0004accaf |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5NzMyOjFFQzc6OTlBMDIxOkQ0RTc3Nzo2QTRFRjZCNiIsInZpc2l0b3JfaWQiOiI2NDMwMjA4NzU1Njg2NjM1MTkwIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 0ea72692e8ee182d454f6a7e957e0713dd3af1cc1ece15f8c482663330458acd |
| hovercard-subject-tag | pull_request:2627202620 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/cppcheck-opensource/cppcheck/pull/7636/files |
| twitter:image | https://avatars.githubusercontent.com/u/20650935?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/20650935?s=400&v=4 |
| og:image:alt | Change Summary Currently, if a push to branchA triggers the CodeQL workflow, and shortly after a subsequent push on the same branchA triggers the CodeQL workflow, both runs will run. With these cha... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | b92d11c0aa4a77d54ef4af1078b6a15fb5a70a215b30c4ecf28889d5a8e656d9 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/cppcheck-opensource/cppcheck git https://github.com/cppcheck-opensource/cppcheck.git |
| octolytics-dimension-user_id | 278097703 |
| octolytics-dimension-user_login | cppcheck-opensource |
| octolytics-dimension-repository_id | 143131 |
| octolytics-dimension-repository_nwo | cppcheck-opensource/cppcheck |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 143131 |
| octolytics-dimension-repository_network_root_nwo | cppcheck-opensource/cppcheck |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 2b8f23afb982271f1b22258a94aede67a6b77760 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width