undefined method `data' for #<Grit::Submodule "20...40">
Created by: Zhann
Since upgrading to Gitlab 5.3, some 'compare changes' views give a 500 error.
For example:
Mike pushed to branch master at repo
bc775a23d Mike – Merge branch 'feature/foo'
a77bc5127 Mike – Merge branch 'feature/bar'
... and 2 more commits. Compare → 566169ab...bc775a23
I can view the commits separately, but not through the compare view.
This is not true for all compare views, some do work (all 'compares' before upgrading to 5.3 also still work).
This is what the logs are telling me:
ActionView::Template::Error (undefined method `data' for #<Grit::Submodule "200f642d9122243ee99cab31fb4ecd9243199d40">):
40: .content
41: -# Skipp all non non-supported blobs
42: - next unless file.respond_to?('text?')
43: - if file.text?
44: = render "commits/text_file", diff: diff, index: i
45: - elsif file.image?
46: - old_file = Gitlab::Git::Blob.new(@repository, @commit.parent_id, @ref, diff.old_path) if @commit.parent_id
app/views/commits/_diffs.html.haml:43:in `block in _app_views_commits__diffs_html_haml__685016852330260568_75050860'
app/views/commits/_diffs.html.haml:17:in `each'
app/views/commits/_diffs.html.haml:17:in `each_with_index'
app/views/commits/_diffs.html.haml:17:in `_app_views_commits__diffs_html_haml__685016852330260568_75050860'
app/views/compare/show.html.haml:23:in `_app_views_compare_show_html_haml__3689822041389927697_68691180'