Knowledge Drop

refs/heads/branch REJECTED_OTHER_REASON: pre-receive hook declined

  • 7 May 2021
  • 1 reply

Userlevel 4

Last tested: Apr 2, 2020

Some users enforce strict policies on their commits from their remote git provider. These sometimes come in the form of pre-commit or pre-receive hooks. These are essentially scripts that git executes before or after an event, like a commit, or a push, that check things such as the length of the commit, the domain the commit is coming from, specified naming conventions needed, and so on. 

What happens?

if a commit or push made through Looker doesn't pass the hook's rules, you'll see an error like this: 


What does this mean?

This commit or deploy is essentially stuck in limbo - Looker thought it was ok, but the remote repository disagreed and sent it back. If we can figure out what is specified in the hook's rules, we might just be able to make a small change, revalidate LookML and make new commit with a message that fits the bill. But if a specific domain is required to deploy code to production changes are required on the side of the remote Git provider - the 'looker' user has to be allowed by any hook involved in the push event. 


This content is subject to limited support.                



1 reply

Userlevel 1

This particular issue has also been seen when there’s an issue with the key Looker is using to authenticate to the git provider. If you haven’t configured any hooks, or don’t believe that to be the issue, it’d be worth resetting your git connection with a new deploy key as a troubleshooting step.