diff options
| -rw-r--r-- | bot/exts/utils/pep.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/bot/exts/utils/pep.py b/bot/exts/utils/pep.py index e0b06d63e..d642c902a 100644 --- a/bot/exts/utils/pep.py +++ b/bot/exts/utils/pep.py @@ -39,6 +39,10 @@ class PythonEnhancementProposals(Cog): self.last_refreshed_peps = datetime.now() async with self.bot.http_session.get(self.PEPS_LISTING_API_URL) as resp: + if resp.status != 200: + log.warning(f"Fetching PEP URLs from GitHub API failed with code {resp.status}") + return + listing = await resp.json() log.trace("Got PEP URLs listing from GitHub API") |