500 Error loading a license file for a repository that has an inconsistent HEAD
Rugged::Repository#head throws Rugged::ReferenceError
if the repository HEAD points to a branch that does not exist (e.g. refs/heads/master
).
https://sentry.gitlap.com/gitlab/gitlabcom/issues/137296/
Rugged::ReferenceError: reference 'refs/heads/master' not found
lib/gitlab/metrics/instrumentation.rb:159:in `head'
.measure { super }
lib/gitlab/metrics/instrumentation.rb:159:in `block in head'
.measure { super }
lib/gitlab/metrics/method_call.rb:36:in `measure'
retval = yield
lib/gitlab/metrics/instrumentation.rb:159:in `head'
.measure { super }
lib/gitlab/metrics/instrumentation.rb:159:in `block in last_commit'
.measure { super }
...
(202 additional frame(s) were not displayed)
ActionView::Template::Error: reference 'refs/heads/master' not found
ActionView::Template::Error: reference 'refs/heads/master' not found
Edited by Stan Hu