Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

移除交互式管理中的ob11 #268

Merged
merged 9 commits into from
Jun 11, 2023
Merged

移除交互式管理中的ob11 #268

merged 9 commits into from
Jun 11, 2023

Conversation

felinae98
Copy link
Collaborator

No description provided.

@netlify
Copy link

netlify bot commented Jun 6, 2023

Deploy Preview for nonebot-bison ready!

Name Link
🔨 Latest commit bdb3429
🔍 Latest deploy log https://app.netlify.com/sites/nonebot-bison/deploys/64857747516a9e000934492b
😎 Deploy Preview https://deploy-preview-268--nonebot-bison.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@codecov
Copy link

codecov bot commented Jun 6, 2023

Codecov Report

Patch coverage: 89.43% and project coverage change: -0.23 ⚠️

Comparison is base (3fc913f) 81.52% compared to head (bdb3429) 81.30%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #268      +/-   ##
==========================================
- Coverage   81.52%   81.30%   -0.23%     
==========================================
  Files          52       63      +11     
  Lines        3009     3150     +141     
==========================================
+ Hits         2453     2561     +108     
- Misses        556      589      +33     
Flag Coverage Δ
smoke-test 81.30% <89.43%> (-0.23%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
nonebot_bison/scheduler/scheduler.py 67.04% <25.00%> (-0.38%) ⬇️
...t_bison/config/migrations/a5466912fad0_map_user.py 50.00% <50.00%> (ø)
nonebot_bison/admin_page/api.py 38.18% <57.14%> (+1.14%) ⬆️
nonebot_bison/post/custom_post.py 76.47% <70.58%> (ø)
nonebot_bison/post/post.py 76.98% <75.00%> (+0.18%) ⬆️
nonebot_bison/utils/__init__.py 55.93% <75.00%> (ø)
...fig/migrations/8d3863e9d74b_remove_uid_and_type.py 78.57% <78.57%> (ø)
nonebot_bison/config/db_migration.py 95.34% <80.00%> (-2.09%) ⬇️
nonebot_bison/config/db_model.py 97.72% <80.00%> (-2.28%) ⬇️
nonebot_bison/send.py 76.78% <82.60%> (-2.58%) ⬇️
... and 21 more

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@felinae98 felinae98 force-pushed the feat/multi-adapter branch 2 times, most recently from 860459e to f52babd Compare June 9, 2023 06:03
Comment on lines 74 to 90
if raw_id_text == "查询":
url = "https://nonebot-bison.netlify.app/usage/#%E6%89%80%E6%94%AF%E6%8C%81%E5%B9%B3%E5%8F%B0%E7%9A%84-uid"
msg = Text(url)
try:
from nonebot.adapters.onebot.v11 import MessageSegment

title = "Bison所支持的平台UID"
content = "查询相关平台的uid格式或获取方式"
image = "https://s3.bmp.ovh/imgs/2022/03/ab3cc45d83bd3dd3.jpg"
msg.overwrite(
SupportedAdapters.onebot_v11,
MessageSegment.share(
url=url, title=title, content=content, image=image
),
)
except ImportError:
pass
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里没有ob11的话输入查询就没有消息回复了吗?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

只会回复链接

nonebot_bison/config_manager/add_sub.py Outdated Show resolved Hide resolved
nonebot_bison/config_manager/__init__.py Outdated Show resolved Hide resolved


@group_manage_matcher.handle()
async def send_group_list(bot: Bot, event: PrivateMessageEvent, state: T_State):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

感觉这个 Bot 可以从 v11 里面导入,毕竟都用上 PrivateMessageEvent 了。

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

未来要改成抽象的event,所以这里还是bot基类吧

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

原来是战未来(

nonebot_bison/config_manager/del_sub.py Outdated Show resolved Hide resolved
nonebot_bison/config_manager/add_sub.py Outdated Show resolved Hide resolved
nonebot_bison/config_manager/query_sub.py Outdated Show resolved Hide resolved
nonebot_bison/config_manager/add_sub.py Outdated Show resolved Hide resolved
@felinae98 felinae98 added the enhancement New feature or request label Jun 11, 2023
@felinae98 felinae98 added this to the 支持多种 adapter milestone Jun 11, 2023
@felinae98 felinae98 linked an issue Jun 11, 2023 that may be closed by this pull request
4 tasks
@felinae98 felinae98 merged commit a1b4f2f into main Jun 11, 2023
28 checks passed
@felinae98 felinae98 deleted the feat/multi-adapter branch June 11, 2023 07:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

支持多种 adapter
3 participants