Skip to content

Commit

Permalink
Small analyze_prs improvements
Browse files Browse the repository at this point in the history
Don't error out if num users provided is greater than
returned total.

Drop users with 0 total prs.
  • Loading branch information
jerry-skydio committed Mar 11, 2024
1 parent 0fc6b0e commit 437ce87
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions scripts/analyze_prs.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,12 @@
total_revup += 1
users[name][1] += 1

# Delete users from the list with 0 prs
for user in list(users.keys()):
if users[user][0] == 0:
del users[user]
args.num_users = min(args.num_users, len(users))

print("Total PRs: {}".format(total))
print("Total revup PRs: {}".format(total_revup))
print(
Expand Down

0 comments on commit 437ce87

Please sign in to comment.