exp is now exc
This commit is contained in:
@@ -123,16 +123,16 @@ async def cmd_import(app: PyroClient, msg: Message):
|
||||
for name in handle.namelist()
|
||||
]
|
||||
_ = await asyncio.gather(*tasks)
|
||||
except Exception as exp:
|
||||
except Exception as exc:
|
||||
logger.error(
|
||||
"Could not import '%s' due to %s: %s",
|
||||
answer.document.file_name,
|
||||
exp,
|
||||
exc,
|
||||
format_exc(),
|
||||
)
|
||||
await answer.reply_text(
|
||||
app._("import_unpack_error", "message", locale=user.locale).format(
|
||||
exp, format_exc()
|
||||
exc, format_exc()
|
||||
)
|
||||
)
|
||||
return
|
||||
@@ -165,12 +165,12 @@ async def cmd_import(app: PyroClient, msg: Message):
|
||||
compress=False,
|
||||
caption="queue",
|
||||
)
|
||||
except UnexpectedStatus as exp:
|
||||
except UnexpectedStatus as exc:
|
||||
logger.error(
|
||||
"Could not upload '%s' from '%s': %s",
|
||||
filename,
|
||||
Path(f"{app.config['locations']['tmp']}/{tmp_dir}"),
|
||||
exp,
|
||||
exc,
|
||||
)
|
||||
await msg.reply_text(
|
||||
app._(
|
||||
|
Reference in New Issue
Block a user