Skip to content

Commit 44d147e

Browse files
author
Maximilian Karl
committed
Fix extract user. A name is sometimes not set!
1 parent 6e42bf6 commit 44d147e

File tree

3 files changed

+22
-5
lines changed

3 files changed

+22
-5
lines changed

docs/changes.rst

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,4 +65,9 @@ Version 1.1.5 (Mai 27, 2021)
6565
Version 1.1.6 (Mai 28, 2021)
6666
-----------------------------------
6767

68-
* define unknown users takes now a dictionary in with unknown user as key and id as value. If the user is doesnt exists then a new user will be added.
68+
* define unknown users takes now a dictionary in with unknown user as key and id as value. If the user is doesnt exists then a new user will be added.
69+
70+
Version 1.1.7 (Mai 28, 2021)
71+
-----------------------------------
72+
73+
* Fix extract user. A name is sometimes not set!

github2pandas/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = '1.1.6'
1+
__version__ = '1.1.7'

github2pandas/utility.py

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -443,9 +443,21 @@ def extract_user_data(user, users_ids, data_root_dir):
443443
user_data["anonym_uuid"] = generate_id(seed=user.node_id)
444444
users_ids[user.node_id] = user_data["anonym_uuid"]
445445
user_data["id"] = user.node_id
446-
user_data["name"] = user.name
447-
user_data["email"] = user.email
448-
user_data["login"] = user.login
446+
try:
447+
user_data["name"] = user.name
448+
except:
449+
print("No User name in:")
450+
print(data_root_dir)
451+
try:
452+
user_data["email"] = user.email
453+
except:
454+
print("No User email in:")
455+
print(data_root_dir)
456+
try:
457+
user_data["login"] = user.login
458+
except:
459+
print("No User login in:")
460+
print(data_root_dir)
449461
try:
450462
user_data["alias"] = user.alias
451463
except:

0 commit comments

Comments
 (0)