- 
          
- 
                Notifications
    You must be signed in to change notification settings 
- Fork 6.6k
[CI Energy Waste] Deduplicate static checks in CI workflow #15739
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
Conversation
Combine typecheck, lint, and yarn-validate jobs into a single static-checks job to eliminate duplication of setup steps and dependencies.
| ✅ Deploy Preview for jestjs ready!Built without sensitive environment variables 
 To edit notification comments on pull requests, go to your Netlify project configuration. | 
| babel-jest
 babel-plugin-jest-hoist
 babel-preset-jest
 create-jest
 @jest/diff-sequences
 expect
 @jest/expect-utils
 jest
 jest-changed-files
 jest-circus
 jest-cli
 jest-config
 @jest/console
 @jest/core
 @jest/create-cache-key-function
 jest-diff
 jest-docblock
 jest-each
 @jest/environment
 jest-environment-jsdom
 @jest/environment-jsdom-abstract
 jest-environment-node
 @jest/expect
 @jest/fake-timers
 @jest/get-type
 @jest/globals
 jest-haste-map
 jest-jasmine2
 jest-leak-detector
 jest-matcher-utils
 jest-message-util
 jest-mock
 @jest/pattern
 jest-phabricator
 jest-regex-util
 @jest/reporters
 jest-resolve
 jest-resolve-dependencies
 jest-runner
 jest-runtime
 @jest/schemas
 jest-snapshot
 @jest/snapshot-utils
 @jest/source-map
 @jest/test-result
 @jest/test-sequencer
 @jest/transform
 @jest/types
 jest-util
 jest-validate
 jest-watcher
 jest-worker
 pretty-format
 commit:  | 
| 
 Can I ask how does this compares with an average annual tuition fee at the University of Zurich? (That is irony, of course. But I think the question is legit, because you titled this PR with: "Energy Waste". Do you see the point?) | 
| @mrazauskas , indeed ... the question is ''legit''. You're absolutely right that $17 won’t fund a semester at the University of Zurich but could plant a dozen trees. And while that may still sound minor, it’s symbolic of something larger. GitHub nowadays hosts about 420 million repositories. If each of them approximately were to waste just one second of runner time per day, that would amount to 7 million minutes wasted daily. At GitHub's billing rate of $0.008 per minute, this seemingly minor inefficiency would result in over $56 000 per day, or even more than $20 million annually, in excess compute costs. But the story is not about the financial dimension .. it's the env footprint: 1 s per repo per day would translate to roughly 2100 kWh wasted daily (for the basic ubuntu-latest runner), or about 730 000 kWh annually, equivalent to the yearly consumption of dozens of households in a developed country. | 
| You are manipulating with numbers. That is it. GitHub or any other responsible corporation should(!) and must(!) invest into education of upcoming developers. I am rather sure they do! (For instance, they do not take a penny from open source projects. These are in many case the learning projects, actually. What about the University of Zurich? Do they charge you for learning? Could you please calculate  and provide the number of  That is not anyhow taken into account of your “research“. Really sorry about the question marks, but I still find it questionable. The numbers you provide are manipulative and not based on reality. | 
| @souhailaS Thank you @mrazauskas please spend some time reflecting on your conduct | 
| This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. | 
Context
We conducted an analysis of the
nodejs.ymlworkflow run history using GitHub API data from recent successful executions. The analysis revealed potential resource optimisation in setup steps across three static check jobs (typecheck,lint,yarn-validate), each performing identical dependency installation and environment setup.Change
Combined three jobs into one
static-checksjob, eliminating redundant setup (installations and checkouts)Impact
Based on the runs history this workflow. We could estimate:
Technical
Files
.github/workflows/nodejs.ymlAdditional Context
We are a team of researchers from University of Zurich (https://www.ifi.uzh.ch/en/zest.html) currently working on automating energy optimizations in GitHub Actions workflows. This optimization maintains full functionality while potentially reducing computational overhead and energy consumption.
souhaila.serbout@uzh.ch