git_stats icon indicating copy to clipboard operation
git_stats copied to clipboard

Error when generate: last_commit is nil: GitStats::GitData::Repo

Open Ridermansb opened this issue 9 years ago • 7 comments

within the repository by executing:: git_stats generate

fatal: |: no such path in the working tree.
Use 'git <command> -- <path>...' to specify paths that do not exist locally.
C:in `rescue in files_by_extension_count': GitStats::GitData::Repo#files_by_extension_count delegated to last_commit.files_by_extension_count, but last_commit is nil: GitStats::GitData::Repo C:/Users/Riderman/Documents/..MyRepo.. (Module::DelegationError)
        from C:in `files_by_extension_count'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/charts/repo_charts.rb:13:in `block in files_by_extension'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/charts/chart.rb:13:in `initialize'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/charts/repo_charts.rb:11:in `new'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/charts/repo_charts.rb:11:in `files_by_extension'
        from C:in `files_by_extension'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/files/_files.haml:15:in `block in singletonclass'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/files/_files.haml:65527:in `instance_eval'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/files/_files.haml:65527:in `singletonclass'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/files/_files.haml:65525:in `__tilt_15822660'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/template.rb:155:in `call'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/template.rb:155:in `evaluate'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/haml.rb:17:in `evaluate'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/template.rb:96:in `render'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/template.rb:15:in `render'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/view_data.rb:18:in `render_partial'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/files/by_extension.haml:1:in `block in singletonclass'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/files/by_extension.haml:65526:in `instance_eval'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/files/by_extension.haml:65526:in `singletonclass'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/files/by_extension.haml:65524:in `__tilt_15822660'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/template.rb:155:in `call'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/template.rb:155:in `evaluate'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/haml.rb:17:in `evaluate'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/template.rb:96:in `render'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/template.rb:13:in `block in render'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/layout.haml:30:in `block in singletonclass'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/layout.haml:65526:in `instance_eval'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/layout.haml:65526:in `singletonclass'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/templates/layout.haml:65524:in `__tilt_15822660'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/template.rb:155:in `call'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/template.rb:155:in `evaluate'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/haml.rb:17:in `evaluate'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/tilt-2.0.1/lib/tilt/template.rb:96:in `render'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/template.rb:13:in `render'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/view.rb:15:in `block in render_all'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/view.rb:14:in `each'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/stats_view/view.rb:14:in `render_all'
        from C:in `render_all'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/lib/git_stats/cli.rb:18:in `generate'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
        from C:/ruby193/lib/ruby/gems/1.9.1/gems/git_stats-1.0.14/bin/git_stats:10:in `<top (required)>'
        from C:/ruby193/bin/git_stats:23:in `load'
        from C:/ruby193/bin/git_stats:23:in `<main>'

Ridermansb avatar Mar 31 '15 01:03 Ridermansb

Same error.... :(

Dhumez-Sebastien avatar Jun 10 '15 18:06 Dhumez-Sebastien

Got same error

eko24 avatar Sep 29 '15 08:09 eko24

Another one :(

aguedob avatar Oct 27 '15 08:10 aguedob

Também estou com o mesmo erro!, alguma previsão para ajustar? Seria somente no windows?

MaiconSpielmann avatar Jan 27 '17 15:01 MaiconSpielmann

Same problem here. To provide some additional info, I installed git_stats using chocolatey. It does not matter how big or small the git repo. After it didn't work on my very large repo, I also tried it on a repo with just one file and one commit.

korthout avatar Oct 20 '17 08:10 korthout

same error.. did this solved?

JoseYUE avatar Jun 25 '18 06:06 JoseYUE

same error :(

adamsiemion avatar Sep 16 '18 20:09 adamsiemion