From 72d4b55b6a74b1e567cec007231b8e3c144b5d7f Mon Sep 17 00:00:00 2001 From: Michael Still Date: Fri, 28 Mar 2014 13:09:36 +1100 Subject: [PATCH] Handle missing emails. --- mirror_fetchers.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/mirror_fetchers.py b/mirror_fetchers.py index 8d0fa53..596bf77 100755 --- a/mirror_fetchers.py +++ b/mirror_fetchers.py @@ -3,6 +3,7 @@ import datetime import json import os +import sys import urllib @@ -108,7 +109,9 @@ for filename in changed_merge_files: if j['type'] == 'comment-added': author = j['author'].get('username', None) if not author: - author = j['author']['email'] + author = j['author'].get('email', None) + if not author: + continue number = j['change']['number'] patchset = j['patchSet']['number']