exp is now exc

This commit is contained in:
2023-08-16 13:27:23 +02:00
parent 5e8506cc12
commit 1d88076285
6 changed files with 37 additions and 37 deletions

View File

@@ -104,8 +104,8 @@ class PyroClient(PyroClient):
logger.warning(
"Could not send startup message to bot owner. Perhaps user has not started the bot yet."
)
except Exception as exp:
logger.exception("Update check failed due to %s: %s", exp, format_exc())
except Exception as exc:
logger.exception("Update check failed due to %s: %s", exc, format_exc())
if self.config["mode"]["post"]:
if self.config["posting"]["use_interval"]:
@@ -155,8 +155,8 @@ class PyroClient(PyroClient):
filepath = await self.download_media(
submission, file_name=self.config["locations"]["tmp"] + sep
)
except Exception as exp:
raise SubmissionUnavailableError() from exp
except Exception as exc:
raise SubmissionUnavailableError() from exc
elif not Path(
f"{self.config['locations']['data']}/submissions/{db_entry['temp']['uuid']}/{db_entry['temp']['file']}",
@@ -204,8 +204,8 @@ class PyroClient(PyroClient):
# ),
# caption="queue",
# )
except UnexpectedStatus as exp:
raise SubmissionUnsupportedError(str(filepath)) from exp
except UnexpectedStatus as exc:
raise SubmissionUnsupportedError(str(filepath)) from exc
response_dict = (
{}