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

force pushes to main branch cause lighthouse to no longer start any builds for a given repo #1532

Open
helmlover opened this issue Mar 29, 2023 · 1 comment

Comments

@helmlover
Copy link

The pod lighthouse-webhooks-*' logs the following error and is unable to start builds after a force push to the main branch:

{"Branch":"master","Clone":"http://anonymized.git","ID":"7750","Link":"http://anonymized/browse","Name":"anonymized","Namespace":"anonymized","Webhook":"push","error":"failed to create agent: failed to calculate in repo config: failed to load trigger config for repository anonymized/anonymized for ref : failed to switch to ref : failed to fetch repository anonymized/anonymized: error pulling: exit status 128 From http://anonymized\n + 39cef83...5b96277 master     -\u003e origin/master  (forced update)\nhint: You have divergent branches and need to specify how to reconcile them.\nhint: You can do so by running one of the following commands sometime before\nhint: your next pull:\nhint: \nhint:   git config pull.rebase false  # merge\nhint:   git config pull.rebase true   # rebase\nhint:   git config pull.ff only       # fast-forward only\nhint: \nhint: You can replace \"git config\" with \"git config --global\" to set a default\nhint: preference for all repositories. You can also pass --rebase, --no-rebase,\nhint: or --ff-only on the command line to override the configured default per\nhint: invocation.\nfatal: Need to specify how to reconcile divergent branches.\n","head":"5b962770018594a9076066421e3d5eaaebc2e0d2","level":"error","msg":"Error creating agent for PushEvent.","org":"anonymized","ref":"refs/heads/master","repo":"anonymized","time":"2023-03-29T14:32:51Z"}

Reproducible with bitbucketserver as well as github.

Now, we all know that force pushes to a main branch are fishy, but imo it is still a lighthouse bug that should be fixed!

@msvticket
Copy link
Member

Which version of lighthouse have you tested this in?

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

No branches or pull requests

2 participants