Skip to content

Commit 5275451

Browse files
authored
Merge pull request #1633 from GSA/main
04/03/2025 Production Deploy
2 parents c2345c2 + 5e35441 commit 5275451

File tree

18 files changed

+708
-2123
lines changed

18 files changed

+708
-2123
lines changed

.github/workflows/checks.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ jobs:
6464
NOTIFY_E2E_TEST_PASSWORD: ${{ secrets.NOTIFY_E2E_TEST_PASSWORD }}
6565
- name: Check coverage threshold
6666
# TODO get this back up to 95
67-
run: poetry run coverage report -m --fail-under=94
67+
run: poetry run coverage report -m --fail-under=93
6868

6969
validate-new-relic-config:
7070
runs-on: ubuntu-latest

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ test: ## Run tests and create coverage report
9595
poetry run coverage run --omit=*/migrations/*,*/tests/* -m pytest --maxfail=10
9696

9797
## TODO set this back to 95 asap
98-
poetry run coverage report -m --fail-under=94
98+
poetry run coverage report -m --fail-under=93
9999
poetry run coverage html -d .coverage_cache
100100

101101
.PHONY: py-lock

app/clients/document_download.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ def upload_document(self, service_id, file_contents, is_csv=None):
3333
"document": file_contents,
3434
"is_csv": is_csv or False,
3535
},
36+
timeout=30
3637
)
3738

3839
response.raise_for_status()

app/clients/performance_platform/performance_platform_client.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ def send_stats_to_performance_platform(self, payload):
2929
self.performance_platform_url + payload["dataType"],
3030
json=payload,
3131
headers=headers,
32+
timeout=30
3233
)
3334

3435
if resp.status_code == 200:

app/cronitor.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ def ping_cronitor(command):
3535
params={
3636
"host": current_app.config["API_HOST_NAME"],
3737
},
38+
timeout=30
3839
)
3940
resp.raise_for_status()
4041
except requests.RequestException as e:

app/dao/services_dao.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -629,7 +629,8 @@ def dao_fetch_stats_for_service_from_days_for_user(
629629
).group_by(total_substmt.c.hour)
630630

631631
total_notifications = {
632-
row.hour: row.total_notifications for row in db.session.execute(total_stmt).all()
632+
row.hour: row.total_notifications
633+
for row in db.session.execute(total_stmt).all()
633634
}
634635

635636
stmt = (

app/notifications/sns_cert_validator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def get_certificate(url):
3030
res = redis_store.get(url)
3131
if res is not None:
3232
return res
33-
res = requests.get(url).text
33+
res = requests.get(url, timeout=30).text
3434
redis_store.set(url, res, ex=60 * 60) # 60 minutes
3535
_signing_cert_cache[url] = res
3636
return res

app/notifications/sns_handlers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ def sns_notification_handler(data, headers):
5858
if "SubscribeUrl" in message
5959
else message.get("SubscribeURL")
6060
)
61-
response = requests.get(url)
61+
response = requests.get(url, timeout=30)
6262
try:
6363
response.raise_for_status()
6464
except Exception as e:

app/notifications/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ def confirm_subscription(confirmation_request):
88
current_app.logger.warning("SubscribeURL does not exist or empty")
99
return
1010

11-
response = requests.get(url)
11+
response = requests.get(url, timeout=30)
1212
try:
1313
response.raise_for_status()
1414
except Exception as e:

migrations/versions/0416_readd_e2e_test_user.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ def upgrade():
4444
conn = op.get_bind()
4545

4646
# delete the old user because
47-
delete_sql = """
48-
delete from users where email_address='[email protected]'
47+
delete_sql = f"""
48+
delete from users where email_address='{email_address}'
4949
"""
5050

5151
insert_sql = """

0 commit comments

Comments
 (0)