maximilien / ghtrack

A python tool to keep track of GitHub users stats
Apache License 2.0
3 stars 3 forks source link

Traceback when --show-all-stats not used #9

Closed maximilien closed 11 months ago

maximilien commented 3 years ago

Bug report

./ght stats september knative --commits --issues \
                        --users=maximilien,octocat \
                        --all-repos \
                        --output=text \
                        --summarize \
                        --rate-limit-random \
                        --rl-max=150 \
                        --rl-sleep=5m

results in

Traceback (most recent call last):
  File "./ghtrack.py", line 70, in <module>
    rc = command.execute()
  File "/Users/maximilien/github/ghtrack/cli.py", line 630, in execute
    rc = func()
  File "/Users/maximilien/github/ghtrack/cli.py", line 767, in stats
    self._update_users_commits()
  File "/Users/maximilien/github/ghtrack/cli.py", line 416, in _update_users_commits
    self._update_repo_stats('commits', self.users_commits)
  File "/Users/maximilien/github/ghtrack/cli.py", line 326, in _update_repo_stats
    self.repos_stats[repo_name][data] += user_data_map[repo_name]
KeyError: 'commits'

Expected behavior

no errors

Steps to reproduce the problem

issue command above. If you include --show-all-stats then command executes fine.

./ght version

./ght --version
GH Track v0.3.5.3

Python version

Python 2.7.15

/kind bug

github-actions[bot] commented 11 months ago

This issue appears to be staled. Please update status and need or risk for it to be archived.