diff --git a/commits/config/categories b/commits/config/categories index 136eb73..a7a92c6 100644 --- a/commits/config/categories +++ b/commits/config/categories @@ -23,6 +23,7 @@ "Stellar Science" Provider "Sun Microsystems" Provider "Trail of Bits" Other +"University of Sydney" Other "Wind River" Provider "Worldline Global" Provider Aerospike Provider diff --git a/commits/config/employers b/commits/config/employers index d07550a..e9f1095 100644 --- a/commits/config/employers +++ b/commits/config/employers @@ -7,6 +7,7 @@ 1136268146@qq.com Independent 15198894161@139.com Independent 22895992+paragoumba@users.noreply.github.com Independent +3001893+sophist-uk@users.noreply.github.com Independent 3310288189@qq.com GSoC 33860799+a97410985@users.noreply.github.com Independent 344369869@qq.com Independent @@ -39,11 +40,13 @@ alan.cuevamr@gmail.com GSoC alex.fan.q@gmail.com Gentoo andrew@linuxjedi.co.uk MariaDB Plc. < 2020-08-15 andrew@linuxjedi.co.uk MariaDB Foundation +andrew.daugherity@gmail.com Independent angeloudy@gmail.com Independent anthonyryan1@gmail.com Whatbox arkamar@atlas.cz Gentoo askeblad@outlook.com Independent aun.sokolov@gmail.com Independent +aurelien@aurel32.net Independent bertrandop@gmail.com CONNECT bluemrp9@gmail.com Independent brad@comstyle.com OpenBSD @@ -101,6 +104,7 @@ hsspig@gmail.com Independent jonas.karlsson@kau.se Independent jonathan.sabbe@gmail.com Worldline Global jordy@pwning.systems Independent +jtojnar@gmail.com Independent justin@jagieniak.net Independent junqi_xie@outlook.com GSoC # A large Ruby on Rails contributor @@ -170,6 +174,7 @@ pavlich_eng00@mail.ru Independent pkubaj@users.noreply.github.com HardenedBSD plainbanana@mustardon.tokyo Independent pmacontrol@68koncept.com Independent +psz@maths.usyd.edu.au University of Sydney rahulanand16nov@gmail.com Independent raj.khem@gmail.com Comcast rantal5030@gmail.com Independent diff --git a/pull-requests/README.md b/pull-requests/README.md index 34b1e8d..bcfb4b8 100644 --- a/pull-requests/README.md +++ b/pull-requests/README.md @@ -2,7 +2,7 @@ ### get_prs.py -This tool gets the PR counts for 2022 and stores them in `prs-.....csv`. There is rate-limit handling built in because some calls are only allowed to do 30 requests per minute. It will also pause and retry upon 500 server errors. To execute this you will need a GitHub token from https://github.com/settings/tokens/new and set this as the environment variable `GITHUB_TOKEN`. You need to provide a date range using week numbers. For example, to generate a 2022 report: diff --git a/pull-requests/pr_github.py b/pull-requests/pr_github.py index cb38035..694b9bf 100644 --- a/pull-requests/pr_github.py +++ b/pull-requests/pr_github.py @@ -11,21 +11,31 @@ def get_data(url, verbose): - response = requests.get(url, headers = auth_header) - if response.status_code != 200: - print("Failed to get json data: " + str(response.headers)) - exit() - if (int(response.headers['X-RateLimit-Remaining']) <= 2): - if verbose: - print("\nRate limit low, remaining " + response.headers['X-RateLimit-Remaining'] + " sleeping for 30 seconds", end='') + while(True): + response = requests.get(url, headers = auth_header) + if response.status_code == 500: + if verbose: + print("\nServer error, retrying in 30 seconds") + else: + print('*', end='') + sys.stdout.flush() + time.sleep(30) + elif response.status_code != 200: + print("\nFailed to get json data: " + str(response.headers)) + print("URL: " + url) + print("Status code: " + str(response.status_code)) + exit() + elif (int(response.headers['X-RateLimit-Remaining']) <= 2): + if verbose: + print("\nRate limit low, remaining " + response.headers['X-RateLimit-Remaining'] + " sleeping for 30 seconds", end='') + else: + print('_', end='') + sys.stdout.flush() + time.sleep(30) else: - print('_', end='') - time.sleep(30) - else: - print('.', end='') - sys.stdout.flush() - - return response + print('.', end='') + sys.stdout.flush() + return response def get_paginated_data(url, verbose): data = []