Add timeout to requests calls

This commit is contained in:
pixeebot[bot]
2025-01-28 03:09:49 +00:00
committed by GitHub
parent 7aa706d12a
commit 96857ad1d4
8 changed files with 14 additions and 14 deletions

View File

@@ -146,8 +146,8 @@ class Command(BaseCommand):
},
headers={
'Content-Type': 'application/json',
}
)
},
timeout=60)
if response.status_code == 200:
self.stdout.write(self.style.SUCCESS('✓ API endpoint test successful'))

View File

@@ -74,7 +74,7 @@ class EmailService:
f"{settings.FORWARD_EMAIL_BASE_URL}/v1/emails",
json=data,
headers=headers,
)
timeout=60)
# Debug output
print(f"Response Status: {response.status_code}")