-
Notifications
You must be signed in to change notification settings - Fork 8
feat(ruff): add Ruff configuration for code linting and formatting #107
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
Conversation
## Sourcery 评审者指南
此 Pull Request 引入了 Ruff,一个快速的 Python Linter 和格式化工具。它包括 `pyproject.toml` 中的 Ruff 配置(包含基本规则)以及一个 GitHub Actions 工作流,用于在每次推送和 Pull Request 时运行 Ruff。
_由于更改看起来很简单,不需要可视化表示,因此未生成图表。_
### 文件级别更改
| 变更 | 详情 and the other way around.Original review guide in EnglishReviewer's Guide by SourceryThis pull request introduces Ruff, a fast Python linter and formatter, to the project. It includes the Ruff configuration in No diagrams generated as the changes look simple and do not need a visual representation. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
嘿 @g1331 - 我已经审查了你的更改 - 这里有一些反馈:
总体评论:
- 考虑使用
extend-select和extend-ignore而不是select和ignore,以避免意外禁用默认规则。
这是我在审查期间查看的内容
- 🟡 一般问题:发现 1 个问题
- 🟢 安全性:一切看起来都很好
- 🟢 测试:一切看起来都很好
- 🟢 复杂性:一切看起来都很好
- 🟢 文档:一切看起来都很好
帮助我更有用!请点击每个评论上的 👍 或 👎,我将使用反馈来改进你的评论。
Original comment in English
Hey @g1331 - I've reviewed your changes - here's some feedback:
Overall Comments:
- Consider using
extend-selectandextend-ignoreinstead ofselectandignoreto avoid unintentionally disabling default rules.
Here's what I looked at during the review
- 🟡 General issues: 1 issue found
- 🟢 Security: all looks good
- 🟢 Testing: all looks good
- 🟢 Complexity: all looks good
- 🟢 Documentation: all looks good
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
bb63785 to
c32120a
Compare
…ate Ruff configuration
… conflict with Black
7b594a5 to
1e5fc96
Compare
好的,这是翻译成中文的 pull request 总结:
Sourcery 总结
启用 Ruff 进行代码检查和格式化。 这包括添加 Ruff 配置文件和一个 GitHub Actions 工作流程,以便在每次推送和 pull request 时运行 Ruff。
构建:
CI:
Original summary in English
Summary by Sourcery
Enable Ruff for code linting and formatting. This includes adding a Ruff configuration file and a GitHub Actions workflow to run Ruff on each push and pull request.
Build:
CI: