[6.1] NoMethodError (undefined method `diff' for "--broken-diff":String) when looking at large diff
Created by: dan-blanchard
I have two branches that have diverged pretty substantially, so I created a merge request to merge them up. Unfortunately, when you click on the diff tab, the diff isn't there at all and instead in the production.log I see:
Started GET "/nlp/alek/merge_requests/1/diffs?_=1380646328731" for 127.0.0.1 at 2013-10-01 12:52:10 -0400
Processing by Projects::MergeRequestsController#diffs as JS
Parameters: {"_"=>"1380646328731", "project_id"=>"nlp/alek", "id"=>"1"}
Completed 500 Internal Server Error in 282ms
NoMethodError (undefined method `diff' for "--broken-diff":String):
app/models/commit.rb:25:in `block in diff_line_count'
app/models/commit.rb:25:in `each'
app/models/commit.rb:25:in `reduce'
app/models/commit.rb:25:in `diff_line_count'
app/controllers/projects/merge_requests_controller.rb:44:in `diffs'
I also get the same error in the log (and a 500 error page) if I try to just compare the branches:
Started GET "/nlp/alek/compare/master...clean_up_n_test" for 127.0.0.1 at 2013-10-01 13:13:54 -0400
Processing by Projects::CompareController#show as HTML
Parameters: {"project_id"=>"nlp/alek", "from"=>"master", "to"=>"clean_up_n_test"}
Completed 500 Internal Server Error in 866ms
NoMethodError (undefined method `diff' for "--broken-diff":String):
app/models/commit.rb:25:in `block in diff_line_count'
app/models/commit.rb:25:in `each'
app/models/commit.rb:25:in `reduce'
app/models/commit.rb:25:in `diff_line_count'
app/controllers/projects/compare_controller.rb:19:in `show'
This seems related to the issue I previously had with big diffs in 5.1 (#3774 (closed) and #3864).