FotoVerite / babygitter

A git repository Analyzer
MIT License
4 stars 0 forks source link

Failure processing large repositories #2

Open manveru opened 15 years ago

manveru commented 15 years ago

I've just sucessfully run babygitter against my manveru/innate repository (around 700 commits), but it fails for the manveru/ramaze repository (around 3000 commits).

The version of grit I used is 1.1.1, directly from mojombo/grit. I assume that this might actually work on Ruby 1.9 due to larger size of the stack, but the dependencies of babygitter make it somewhat hard to run it there. Any chance to unroll whichever recursive method you used into a loop?

/home/manveru/c/grit/lib/grit/git-ruby/internal/file_window.rb:31:in `[]'/home/manveru/c/grit/lib/grit/git-ruby/internal/file_window.rb:31:in `[]': : stack level too deepstack level too deep ( (SystemStackErrorSystemStackError)
)
  from /home/manveru/c/grit/lib/grit/git-ruby/internal/pack.rb:207:in `find_object_in_index'
  from /home/manveru/c/grit/lib/grit/git-ruby/internal/pack.rb:207:in `find_object_in_index'
  from /home/manveru/c/grit/lib/grit/git-ruby/internal/pack.rb:231:in `find_object'
  from /home/manveru/c/grit/lib/grit/git-ruby/internal/pack.rb:231:in `find_object'
  from /home/manveru/c/grit/lib/grit/git-ruby/internal/pack.rb:70:in `with_idx'
  from /home/manveru/c/grit/lib/grit/git-ruby/internal/pack.rb:70:in `with_idx'
  from /home/manveru/c/grit/lib/grit/git-ruby/internal/pack.rb:230:in `find_object'
  from /home/manveru/c/grit/lib/grit/git-ruby/internal/pack.rb:230:in `find_object'
  from /home/manveru/c/grit/lib/grit/git-ruby/internal/pack.rb:113:in `[]'
  from /home/manveru/c/grit/lib/grit/git-ruby/internal/pack.rb:113:in `[]'
  from /home/manveru/c/grit/lib/grit/git-ruby/repository.rb:78:in `get_raw_object_by_sha1'
  from /home/manveru/c/grit/lib/grit/git-ruby/repository.rb:78:in `get_raw_object_by_sha1'
  from /home/manveru/c/grit/lib/grit/git-ruby/repository.rb:77:in `each'
  from /home/manveru/c/grit/lib/grit/git-ruby/repository.rb:77:in `each'
  from /home/manveru/c/grit/lib/grit/git-ruby/repository.rb:77:in `get_raw_object_by_sha1'
  from /home/manveru/c/grit/lib/grit/git-ruby/repository.rb:77:in `get_raw_object_by_sha1'
   ... 2841 levels...
   ... 2841 levels...
  from /home/manveru/.gem/ruby/1.8/gems/babygitter-1.1.3/lib/babygitter/report_generator/application.rb:89:in `run!'
  from /home/manveru/.gem/ruby/1.8/gems/babygitter-1.1.3/lib/babygitter/report_generator/application.rb:89:in `run!'
  from /home/manveru/.gem/ruby/1.8/gems/babygitter-1.1.3/bin/babygitter-report:10
  from /home/manveru/.gem/ruby/1.8/gems/babygitter-1.1.3/bin/babygitter-report:10
  from /home/manveru/.gem/ruby/1.8/bin/babygitter-report:19:in `load'
  from /home/manveru/.gem/ruby/1.8/bin/babygitter-report:19:in `load'
  from /home/manveru/.gem/ruby/1.8/bin/babygitter-report:19
  from /home/manveru/.gem/ruby/1.8/bin/babygitter-report:19
FotoVerite commented 15 years ago

It's a grit problem. specifically with Grit::Commit.find_all

I've been trying to work out how to fix it. Probably going to try and create a batch method to alleviate this problem.