Skip to content

feat(static_code_audit): 引入 Ruff/Pylint/MyPy 静态审查并集成到 CodeMage 插件生成流程#17

Open
qa296 wants to merge 2 commits intomainfrom
astrbot-llm-code-audit-ruff-pylint-mypy-single-config-requirements
Open

feat(static_code_audit): 引入 Ruff/Pylint/MyPy 静态审查并集成到 CodeMage 插件生成流程#17
qa296 wants to merge 2 commits intomainfrom
astrbot-llm-code-audit-ruff-pylint-mypy-single-config-requirements

Conversation

@qa296
Copy link
Owner

@qa296 qa296 commented Nov 15, 2025

Summary

在 CodeMage 插件生成流程中新增静态代码审查能力,确保生成插件的代码质量与安全性,同时保持非阻塞式审查,不阻断后续流程。

Details

  • 新增静态审查模块 static_auditor.py,基于 Ruff、Pylint、MyPy 对生成的 main.py 进行静态检查并汇总结果。
  • 将静态审查集成到代码生成流程:对生成的代码执行审查并在对话中展示摘要和样例。
  • 引入配置开关 static_code_audit(默认 true),并新增 _conf_schema.json 以支持该配置。
  • 增加 requirements.txt 以安装 Ruff、Pylint、MyPy 等工具;调整 lint 配置以适配审查结果。
  • 新增对现有审查与代码修复流程的集成,使静态问题能够被报告并影响审查语义。

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