mirror of
https://github.com/AstrBotDevs/AstrBot
synced 2026-07-16 17:47:06 +08:00
chore: 新增依赖,移除类型忽略注释
This commit is contained in:
@@ -522,7 +522,7 @@ async def _compress_image_for_provider(
|
||||
if not enabled:
|
||||
return url_or_path
|
||||
return await compress_image(url_or_path, max_size=max_size, quality=quality)
|
||||
except Exception as exc: # noqa: BLE001
|
||||
except Exception as exc:
|
||||
logger.error("Image compression failed: %s", exc)
|
||||
return url_or_path
|
||||
|
||||
@@ -562,7 +562,7 @@ async def _compress_image_for_provider(
|
||||
if not enabled:
|
||||
return url_or_path
|
||||
return await compress_image(url_or_path, max_size=max_size, quality=quality)
|
||||
except Exception as exc: # noqa: BLE001
|
||||
except Exception as exc:
|
||||
logger.error("Image compression failed: %s", exc)
|
||||
return url_or_path
|
||||
|
||||
@@ -650,7 +650,7 @@ async def _process_quote_message(
|
||||
):
|
||||
try:
|
||||
os.remove(compress_path)
|
||||
except Exception as exc: # noqa: BLE001
|
||||
except Exception as exc:
|
||||
logger.warning("Fail to remove temporary compressed image: %s", exc)
|
||||
|
||||
quoted_content = "\n".join(content_parts)
|
||||
|
||||
@@ -69,6 +69,7 @@ dependencies = [
|
||||
"anyio>=4.12.1",
|
||||
"argon2-cffi>=23.1.0",
|
||||
"plumbum>=1.10.0",
|
||||
"textual>=8.1.1",
|
||||
]
|
||||
|
||||
[dependency-groups]
|
||||
@@ -79,6 +80,7 @@ dev = [
|
||||
"pytest-asyncio>=1.1.0",
|
||||
"pytest-cov>=6.2.1",
|
||||
"ruff>=0.15.0",
|
||||
"textual-dev>=1.8.0",
|
||||
]
|
||||
|
||||
[project.scripts]
|
||||
|
||||
Reference in New Issue
Block a user