Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sleep added between API commit request calls #436

Merged
merged 2 commits into from
Mar 22, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions sources/yearly_commit_calculator.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
from asyncio import sleep
from json import dumps
from re import search
from datetime import datetime
Expand Down Expand Up @@ -81,3 +82,6 @@ async def update_data_with_commit_stats(repo_details: Dict, yearly_data: Dict, d
yearly_data[curr_year][quarter][repo_details["primaryLanguage"]["name"]] = {"add": 0, "del": 0}
yearly_data[curr_year][quarter][repo_details["primaryLanguage"]["name"]]["add"] += commit["additions"]
yearly_data[curr_year][quarter][repo_details["primaryLanguage"]["name"]]["del"] += commit["deletions"]

if not EM.DEBUG_RUN:
await sleep(0.4)