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

🎨 修改方法名称 #1591

Merged
merged 1 commit into from
Aug 29, 2024
Merged

🎨 修改方法名称 #1591

merged 1 commit into from
Aug 29, 2024

Conversation

HibiKier
Copy link
Owner

@HibiKier HibiKier commented Aug 29, 2024

Summary by Sourcery

将 CommonUtils 类中的 'is_block' 方法重命名为 'task_is_block',并更新项目中所有相关引用,以提高代码清晰度。

增强功能:

  • 将 CommonUtils 类中的方法 'is_block' 重命名为 'task_is_block',以提高代码库的清晰度和一致性。
Original summary in English

Summary by Sourcery

Rename the 'is_block' method to 'task_is_block' in the CommonUtils class and update all its references across the project to enhance code clarity.

Enhancements:

  • Rename the method 'is_block' to 'task_is_block' in the CommonUtils class to improve clarity and consistency across the codebase.

@HibiKier HibiKier merged commit 21bdb01 into main Aug 29, 2024
2 checks passed
Copy link
Contributor

sourcery-ai bot commented Aug 29, 2024

Sourcery 的审查指南

此拉取请求将 CommonUtils 类中的方法 is_block 重命名为 task_is_block,并更新了其在多个文件中的所有用法。此更改在不改变方法功能的情况下提高了方法目的的清晰度。

文件级更改

更改 详情 文件
将 CommonUtils 类中的方法 'is_block' 重命名为 'task_is_block'
  • 将方法签名从 'async def is_block(cls, module: str, group_id: str
None) -> bool:' 更改为 'async def task_is_block(cls, module: str, group_id: str
更新所有 'is_block' 方法的用法为 'task_is_block'
  • 在群组处理逻辑中将 'CommonUtils.is_block' 更改为 'CommonUtils.task_is_block'
  • 在早晨调度器中将 'CommonUtils.is_block' 更新为 'CommonUtils.task_is_block'
  • 在广播功能中将 'CommonUtils.is_block' 修改为 'CommonUtils.task_is_block'
zhenxun/builtin_plugins/platform/qq/group_handle.py
zhenxun/builtin_plugins/scheduler/morning.py
zhenxun/builtin_plugins/superuser/broadcast/_data_source.py

提示
  • 通过在拉取请求中评论 @sourcery-ai review 来触发新的 Sourcery 审查。
  • 通过直接回复审查评论继续与 Sourcery 的讨论。
  • 您可以随时通过访问您的仪表板来更改审查设置:
    • 启用或禁用 Sourcery 生成的拉取请求摘要或审查指南;
    • 更改审查语言;
  • 如果您有任何问题或反馈,您可以随时联系我们
Original review guide in English

Reviewer's Guide by Sourcery

This pull request renames the method is_block to task_is_block in the CommonUtils class and updates all its usages across multiple files. The change improves the clarity of the method's purpose without altering its functionality.

File-Level Changes

Change Details Files
Renamed method 'is_block' to 'task_is_block' in CommonUtils class
  • Changed method signature from 'async def is_block(cls, module: str, group_id: str
None) -> bool:' to 'async def task_is_block(cls, module: str, group_id: str
Updated all usages of 'is_block' method to 'task_is_block'
  • Changed 'CommonUtils.is_block' to 'CommonUtils.task_is_block' in group handling logic
  • Updated 'CommonUtils.is_block' to 'CommonUtils.task_is_block' in morning scheduler
  • Modified 'CommonUtils.is_block' to 'CommonUtils.task_is_block' in broadcast functionality
zhenxun/builtin_plugins/platform/qq/group_handle.py
zhenxun/builtin_plugins/scheduler/morning.py
zhenxun/builtin_plugins/superuser/broadcast/_data_source.py

Tips
  • Trigger a new Sourcery review by commenting @sourcery-ai review on the pull request.
  • Continue your discussion with Sourcery by replying directly to review comments.
  • You can change your review settings at any time by accessing your dashboard:
    • Enable or disable the Sourcery-generated pull request summary or reviewer's guide;
    • Change the review language;
  • You can always contact us if you have any questions or feedback.

Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

@HibiKier - 我已经审查了你的更改,它们看起来很棒!

这是我在审查期间查看的内容
  • 🟢 一般问题:一切看起来都很好
  • 🟢 安全性:一切看起来都很好
  • 🟢 测试:一切看起来都很好
  • 🟢 复杂性:一切看起来都很好
  • 🟢 文档:一切看起来都很好

Sourcery 对开源项目免费 - 如果你喜欢我们的审查,请考虑分享它们 ✨
帮助我变得更有用!请点击 👍 或 👎 来告诉我每条评论是否有帮助。
Original comment in English

Hey @HibiKier - I've reviewed your changes and they look great!

Here's what I looked at during the review
  • 🟢 General issues: all looks good
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment to tell me if it was helpful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant