Skip to content

Fix CI merge error by disabling windows workflow on pushes to master#29078

Merged
mseri merged 2 commits intoocaml:masterfrom
jmid:disable-win-ci-on-merge
Dec 12, 2025
Merged

Fix CI merge error by disabling windows workflow on pushes to master#29078
mseri merged 2 commits intoocaml:masterfrom
jmid:disable-win-ci-on-merge

Conversation

@jmid
Copy link
Member

@jmid jmid commented Dec 12, 2025

Since the merge of #29040 including 703ece7 I've been getting an error email every time I merge a PR.

(The email has Subject: [ocaml/opam-repository] Run failed: Windows CI - master (9684018)
and a body that says "Windows CI: All jobs were successful" ... but I digress 😅 )

Looking at the GitHub Actions CI interface, I observed that Get changed files is not run on a merge commit, since it is guarded by if: github.event_name != 'push', but the subsequent steps depending on the changed files info are still enabled:

windows-ci-screenshot

Up until 703ece7 the subsequent steps were similarly guarded, so I started by inserting those again.
I then realized that running a workflow on pushes to master only to hit a series of disabled workflow steps that perform any actual checks makes little sense.

This PR therefore disables the windows CI workflow on pushes to master (incl.merge) where checks are disabled already.
It should only make a difference to opam maintainers who hopefully won't get an error email after this.

@jmid jmid marked this pull request as draft December 12, 2025 10:37
@jmid jmid force-pushed the disable-win-ci-on-merge branch from 747f30a to cafe15d Compare December 12, 2025 11:17
@jmid jmid marked this pull request as ready for review December 12, 2025 11:18
@jmid
Copy link
Member Author

jmid commented Dec 12, 2025

OK, this needed a bit back-and-forth but now it should be ready:

  • Since 703ece7 splits the Windows CI into an analyse and (dynamic) build jobs, the latter needed a guard to handle the "no packages" case. Previously we had only 2 jobs with inter-job-step-dependencies already handling this.
  • On merges to master, the Get changed files step was disabled, but the remaining steps weren't, which caused the error.
  • When choosing between "Run a workflow with disabled checks" and "Don't run the workflow" in this case I maintain that the latter is the reasonable choice.

In summary:

@mseri mseri merged commit af00728 into ocaml:master Dec 12, 2025
4 checks passed
@mseri
Copy link
Member

mseri commented Dec 12, 2025

Thanks

@dra27 dra27 mentioned this pull request Dec 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants