[CI] Don't trigger GHA pull_request on PRs from local branches#10636
[CI] Don't trigger GHA pull_request on PRs from local branches#10636straight-shoota wants to merge 1 commit intomasterfrom
Conversation
|
This seems to be working as intended (despite #9890 (comment)). Only jobs triggerd from the push are running. |
|
@straight-shoota That solution wasn't working for me. |
|
Yeah, maybe there was some confusion because the configuration changed after the PR was created. Or some other glitch. I mean this configuration shouldn't really disable all jobs. |
|
Can you not just do: on:
push:
branches:
- master
pull_request:
branches:
- masterSuch that it runs on PRs opened to EDIT: Re-reading the other issue/PR, I'm with Sija on this one. Open a draft PR if you want to run CI/touch up any failures before having it be ready or review. Otherwise we're just wasting CI minutes (even tho they're free 🤷). |
|
@Blacksmoke16 I don't think that'll do. At least not that restrictive. We need PR workflows to trigger for more target branches. Release and master of course, but also occasionally we have stacked PRs where any feature branch can serve as a target for a pull request. And I'm pretty sure we want CI to trigger on any pull request to make sure the code is good when merged. This PR is actually not good in that regard either. I think we should close this. |
|
Okay, then wouldn't it be enough to just remove the branch requirements on |
|
I just don't think it's worth it. We don't push that many branches directly to this repo. And those who are, we typically want to run CI on them, often that's the explicit reason to push them. So unless I'm missing something, I don't see many instances where a branch is pushed directly to this repo, and we could avoid running some extra CI on push events. |
|
Ohh you know what, my confusion came from the fact that for #15954 I opened it via GH UI which made it do both event CI jobs whereas normally I open them from my fork which only does |
See #9890 (comment)
Resolves #9890