mirror of
https://github.com/AstrBotDevs/AstrBot
synced 2026-07-16 01:40:15 +08:00
fix: remove incorrect startup suggestion from version check
This commit is contained in:
@@ -48,7 +48,7 @@ def check_env() -> None:
|
||||
if not (sys.version_info.major == 3 and sys.version_info.minor in (12, 13)):
|
||||
print(
|
||||
f"❌ Python 版本错误: 当前使用 Python {sys.version_info.major}.{sys.version_info.minor}\n"
|
||||
"请使用 uv tool install -e . --force -p 3.12 或 -p 3.13 重新安装",
|
||||
"请使用 uv tool install -e . --force -p 3.12 重新安装",
|
||||
file=sys.stderr,
|
||||
)
|
||||
sys.exit(1)
|
||||
|
||||
@@ -61,7 +61,7 @@ from astrbot.runtime_bootstrap import initialize_runtime_bootstrap
|
||||
if not (sys.version_info.major == 3 and sys.version_info.minor in (12, 13)):
|
||||
print(
|
||||
f"❌ Python 版本错误: 当前使用 Python {sys.version_info.major}.{sys.version_info.minor}\n"
|
||||
"请使用 uv tool install -e . --force -p 3.12 或 -p 3.13 重新安装",
|
||||
"请使用 uv tool install -e . --force -p 3.12 重新安装",
|
||||
file=sys.stderr,
|
||||
)
|
||||
sys.exit(1)
|
||||
|
||||
@@ -430,9 +430,9 @@ async def _sync_skills_to_sandbox(booter: ComputerBooter) -> None:
|
||||
len(managed),
|
||||
)
|
||||
finally:
|
||||
if zip_path.exists():
|
||||
if await zip_path.exists():
|
||||
try:
|
||||
zip_path.unlink()
|
||||
await zip_path.unlink()
|
||||
except Exception:
|
||||
logger.warning(
|
||||
"[Computer] sandbox_sync phase=cleanup status=failed path=%s",
|
||||
|
||||
@@ -109,7 +109,7 @@ class FileUploadTool(FunctionTool):
|
||||
self,
|
||||
context: ContextWrapper[AstrAgentContext],
|
||||
local_path: str,
|
||||
) -> str | None:
|
||||
) -> str:
|
||||
if permission_error := check_admin_permission(context, "File upload/download"):
|
||||
return permission_error
|
||||
sb = await get_booter(
|
||||
|
||||
Reference in New Issue
Block a user