mirror of
https://github.com/nonebot/nonebot2.git
synced 2025-07-28 08:41:29 +00:00
🏷️ 完善 typing 及注释
This commit is contained in:
@ -2,6 +2,12 @@ from nonebot.exception import AdapterException
|
||||
|
||||
|
||||
class DingAdapterException(AdapterException):
|
||||
"""
|
||||
:说明:
|
||||
|
||||
钉钉 Adapter 错误基类
|
||||
|
||||
"""
|
||||
|
||||
def __init__(self) -> None:
|
||||
super.__init__("DING")
|
||||
@ -11,7 +17,7 @@ class ApiError(DingAdapterException):
|
||||
"""
|
||||
:说明:
|
||||
|
||||
API 请求成功返回数据,但 API 操作失败。
|
||||
API 请求返回错误信息。
|
||||
|
||||
"""
|
||||
|
||||
@ -24,6 +30,12 @@ class ApiError(DingAdapterException):
|
||||
|
||||
|
||||
class SessionExpired(DingAdapterException):
|
||||
"""
|
||||
:说明:
|
||||
|
||||
发消息的 session 已经过期。
|
||||
|
||||
"""
|
||||
|
||||
def __repr__(self) -> str:
|
||||
return f"<sessionWebhook is Expired>"
|
||||
|
Reference in New Issue
Block a user