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

gitlab sync action workflow fails for PR from forked repo #811

Closed
sverhoeven opened this issue Feb 20, 2024 · 6 comments · Fixed by #812
Closed

gitlab sync action workflow fails for PR from forked repo #811

sverhoeven opened this issue Feb 20, 2024 · 6 comments · Fixed by #812
Assignees
Labels
bug Something isn't working CI / repository Continuous integration or repository organization

Comments

@sverhoeven
Copy link
Contributor

Describe the bug
I have a (Pull Request)[https://github.com//pull/810] made from a forked repo which mails me about a failed workflow run, but then on PR page the failure is not visible.

To Reproduce
Steps to reproduce the behavior, if relevant, provide the input that triggered the error:

  1. I created a PR Round other cluster + dont add score which was not there before #810
  2. I get a mail with failed worklow run https://github.com/i-VRESSE/haddock3/actions/runs/7972092429
  3. In PR conversation I see a red check in the last commit, but once the other workflows have completed everything is green.

Expected behavior
For branches in forked repo that the https://github.com/i-VRESSE/haddock3/blob/main/.github/workflows/github-to-gitlab-push-sync.yml workflow does not run.

@rvhonorato rvhonorato added bug Something isn't working CI / repository Continuous integration or repository organization labels Feb 22, 2024
@rvhonorato
Copy link
Member

This is related to the action implemented by @amjjbonvin in #798 which was wrongly done.

It can be safely ignored in forked repos, but the action itself needs to be re-configured

@amjjbonvin
Copy link
Member

I would not know how to re-configure it.
It is working for the mirroring to the EU Castiel GitLab (was checked by the reviewers actually)

@sverhoeven
Copy link
Contributor Author

Adding a condition similar to integration test would exclude syncing of branches in forked repos.
See

if: ${{ github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository }}

@rvhonorato
Copy link
Member

I would not know how to re-configure it. It is working for the mirroring to the EU Castiel GitLab (was checked by the reviewers actually)

It can be both wrong and working 😉

@rvhonorato rvhonorato linked a pull request Feb 22, 2024 that will close this issue
@rvhonorato
Copy link
Member

Should be fixed now @sverhoeven 🤞🏽

@sverhoeven
Copy link
Contributor Author

Should be fixed now @sverhoeven 🤞🏽

Great, that is good for any external contributors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working CI / repository Continuous integration or repository organization
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants