Skip to content

Fix workflow triggers for Forked-Repo-PRs #71

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

Merged
merged 3 commits into from
Oct 25, 2023

Conversation

MHHukiewitz
Copy link
Member

@MHHukiewitz MHHukiewitz commented Oct 25, 2023

Problem: build-wheels.yml and pytest-docker.yml would not trigger if a PR was created from a forked repo.

Solution: Trigger all the workflows on direct pushes to main and on any PR to main.

Indication comes from #69 and #47, which were both PRs that did not trigger all workflows and both were attempted merges from 1yam's forked repo.

@MHHukiewitz MHHukiewitz requested a review from hoh October 25, 2023 10:00
@MHHukiewitz MHHukiewitz force-pushed the mhh-trigger-workflows-on-forked-branches branch from 54367aa to 16a1e0d Compare October 25, 2023 10:03
@hoh
Copy link
Member

hoh commented Oct 25, 2023

We should run CI on all branches and Pull Requests.

What about using this ?

on:
  push:
  pull_request:

@MHHukiewitz
Copy link
Member Author

MHHukiewitz commented Oct 25, 2023

on:
  push:
[...]

Won't this cause the CI to trigger on every push on every branch, even without PR in place?

Thought it would be important to save on unnecessary GH actions usage

…a PR was created from a forked repo

Solution: Trigger all the workflows on direct pushes to main and on any PR to main
@MHHukiewitz MHHukiewitz force-pushed the mhh-trigger-workflows-on-forked-branches branch from 16a1e0d to 5d7c602 Compare October 25, 2023 10:17
@hoh
Copy link
Member

hoh commented Oct 25, 2023

Good point.

The main thing that consumes our CI usage is the replication due to the matrix of versions.

We should run:

  • build-wheels.yml on main and PRs that target main
  • code quality on every push
  • skip upgrading packages from the code quality on every push
  • keep pytest-docker.yml on PR to main

…; trigger code-quality on every push

To reduce used compute time on action execution
@hoh hoh merged commit 00592c2 into main Oct 25, 2023
@MHHukiewitz MHHukiewitz deleted the mhh-trigger-workflows-on-forked-branches branch October 25, 2023 13:34
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