Skip to content

Skip CI steps irrelevant to committed changes on PRs#4208

Merged
Gedochao merged 1 commit intoVirtusLab:mainfrom
Gedochao:ci/skip-ci-steps-based-on-changes-category
Apr 7, 2026
Merged

Skip CI steps irrelevant to committed changes on PRs#4208
Gedochao merged 1 commit intoVirtusLab:mainfrom
Gedochao:ci/skip-ci-steps-based-on-changes-category

Conversation

@Gedochao
Copy link
Copy Markdown
Contributor

@Gedochao Gedochao commented Mar 31, 2026

Relevant to:

This is an attempt to save time on running tests irrelevant to changes on a given pull request.
i.e. when changing a doc or adding release notes, it is essentially pointless to run the whole integration suites, which pessimistically can run for hours, due to all the platforms necessary.

A new changes job is added, which classifies changes to categories. Steps in other jobs are then subsequently skipped based on category.
This is a bit sneaky, as the jobs have to still "run" to satisfy our PR checks. The actual status on what was run can be checked based on the time a job elapsed & what was logged.

main branch & release tags bypass this, retaining the old behaviour (in fact, all jobs which don't originate from a PR retain the old behaviour, running everything).

Additionally, override keywords have been added to allow to still run certain test suites even if the code in a PR would imply they're irrelevant. They're checked in the PR description and have syntax in the style of the Scala 3 compiler repo. Documented them in DEV.md.
Not including them in the PR description, as they would actually change behaviour 🙃

Checklist

  • tested the solution locally and it works (can't test locally)
  • ran the code formatter (scala-cli fmt .) (irrelevant)
  • ran scalafix (./mill -i __.fix) (irrelevant)
  • ran reference docs auto-generation (./mill -i 'generate-reference-doc[]'.run) (irrelevant)

How much have your relied on LLM-based tools in this contribution?

extensively, Cursor + Claude

How was the solution tested?

Testing it on the CI, impossible to test locally.

@Gedochao Gedochao force-pushed the ci/skip-ci-steps-based-on-changes-category branch from 582e911 to 4c7e112 Compare March 31, 2026 09:34
@Gedochao Gedochao marked this pull request as ready for review April 6, 2026 10:34
@Gedochao Gedochao requested review from tgodzik and zielinsky April 6, 2026 10:34
Copy link
Copy Markdown
Member

@tgodzik tgodzik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, though it's a lot of changes, so just had a quick look

@Gedochao
Copy link
Copy Markdown
Contributor Author

Gedochao commented Apr 7, 2026

though it's a lot of changes, so just had a quick look

it's also hard to fully test this without getting it on main.
So let's just observe after I merge.

@Gedochao Gedochao merged commit 9ddbdb2 into VirtusLab:main Apr 7, 2026
173 of 184 checks passed
@Gedochao Gedochao deleted the ci/skip-ci-steps-based-on-changes-category branch April 7, 2026 17:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants