Skip to content
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

ci: split into smaller workflows with some improvements #1475

Merged
merged 1 commit into from
Dec 11, 2024

Conversation

alaviss
Copy link
Contributor

@alaviss alaviss commented Dec 11, 2024

Summary

This PR splits our big CI workflow into smaller reusable workflows,
enabling a greater degree of parallelization and improve
maintainability.

Details

Previously, the main workflow runs in stages for each of the tested
platforms. However, this poses a problem where a stage is blocked by the
slowest runner and none of the other runners could move on.

With the release of reusable workflows for Actions, we can now separate
the stages into a different workflow, then parallelize that instead,
allowing faster runners to proceed through test stages ahead of the
rest. The response time for test results should now be greatly improved,
with the M1 runner finishing its run in just 7 minutes.

This separation also opened the doors to customizing how tests are run
for each platforms, and we now only use 1 test batch for *nix while
allocating 3 to Windows. This normalizes test time between Windows and
*nix, while allowing freed up runners to process other jobs.

Lastly, some tiny QoL improvements are added to the pipeline:

  • Test failures will now be displayed at the end of "Run tester" step,
    reducing the number of clicks required to see all failures to 1.
  • The diffoscope container is now used instead of the Ubuntu package,
    reducing installation time and let us receive latest features/bug
    fixes.
  • If there is a diffoscope failure, a test summary is now generated with
    a link to the test report. This should make it a lot easier to get to
    the report should that be necessary.

Previously, the main workflow runs in stages for each of the tested
platforms. However, this poses a problem where a stage is blocked by the
slowest runner and none of the other runners could move on.

With the release of reusable workflows for Actions, we can now separate
the stages into a different workflow, then parallelize that instead,
allowing faster runners to proceed through test stages ahead of the
rest. The response time for test results should now be greatly improved,
with the M1 runner finishing its run in just 7 minutes.

This separation also opened the doors to customizing how tests are run
for each platforms, and we now only use 1 test batch for *nix while
allocating 3 to Windows. This normalizes test time between Windows and
*nix, while allowing freed up runners to process other jobs.

Lastly, some tiny QoL improvements are added to the pipeline:

- Test failures will now be displayed at the end of "Run tester" step,
  reducing the number of clicks required to see all failures to 1.
- The diffoscope container is now used instead of the Ubuntu package,
  reducing installation time and let us receive latest features/bug
  fixes.
- If there is a diffoscope failure, a test summary is now generated with
  a link to the test report. This should make it a lot easier to get to
  the report should that be necessary.
@alaviss alaviss added the ci Continuous Integration label Dec 11, 2024
@alaviss alaviss requested a review from a team as a code owner December 11, 2024 03:51
@alaviss
Copy link
Contributor Author

alaviss commented Dec 11, 2024

/merge

Copy link

Merge requested by: @alaviss

Contents after the first section break of the PR description has been removed and preserved below:


Notes for Reviewers

  • Some numbers based on these runs: old, new
Category Old Pipeline (minutes) New Pipeline (minutes) Diff
Time to completion 34.17 28.12 -17.71%
Time to first testament completion 15.72 7.57 -51.85%
Time to first release binary (any platform) 16.25 5.15 -68.3%

@chore-runner chore-runner bot added this pull request to the merge queue Dec 11, 2024
Merged via the queue into nim-works:devel with commit 2f03e08 Dec 11, 2024
37 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci Continuous Integration
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant