diff options
Diffstat (limited to 'gitsrht/blueprints/stats.py')
-rw-r--r-- | gitsrht/blueprints/stats.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gitsrht/blueprints/stats.py b/gitsrht/blueprints/stats.py index 82c562b..57a9f3e 100644 --- a/gitsrht/blueprints/stats.py +++ b/gitsrht/blueprints/stats.py @@ -32,7 +32,10 @@ def get_contributions(git_repo, tip, since): if timestamp < since_ts: break - week = _week(datetime.fromtimestamp(timestamp)) + try: + week = _week(datetime.fromtimestamp(timestamp)) + except: + continue user = _user(commit.author.email, commit.author.name) contributions[user]['commits'] += 1 contributions[user]['weekly'][week] += 1 |