Skip to content

Newer version of Git may cause 500 error in the repository due to tag warning

Zendesk: https://gitlab.zendesk.com/agent/tickets/57685

I'm am not yet sure if this is a bug (probably), and it may also be related to our Omnibus upgrade from Git 2.8 to 2.10. A customer gets the follow error when attempting to view the repository or tags pages. We suspected a corrupt object in the repo so they ran the check repo Rake task (fsck). It gave the second warning below. There isn't much info about this particular warning online - some people experiencing it but no mention of how to fix it, or if a fix it needed. If indeed it's only a warning, GitLab needs to be able to handle it.

500 error:

NoMethodError (undefined method `committed_date' for nil:NilClass): 
app/models/repository.rb:1344:in `block in tags_sorted_by_committed_date' 
app/models/repository.rb:1344:in `each' 
app/models/repository.rb:1344:in `sort_by' 
app/models/repository.rb:1344:in `tags_sorted_by_committed_date' 
app/models/repository.rb:777:in `tags_sorted_by' 
app/finders/tags_finder.rb:8:in `execute' 
app/controllers/projects/tags_controller.rb:14:in `index' 
lib/gitlab/middleware/multipart.rb:93:in `call' 
lib/gitlab/request_profiler/middleware.rb:15:in `call' 
lib/gitlab/middleware/go.rb:16:in `call' 
lib/gitlab/middleware/readonly_geo.rb:29:in `call'

fsck warning:

warning in tag 279c674f31885b18fd312149e7938850f7bd13bb: 
missingTaggerEntry: invalid format - expected 'tagger' line