Merged
[pre-commit检查切换]: 将 OAT 检查切换为远程 pre-commit hook模式 #6927
[pre-commit检查切换]: 将 OAT 检查切换为远程 pre-commit hook模式 #6927
Merged
liuliu876Add on Oct 23
liuliu876
liuliu876Collaborators
Oct 23

描述

关联的Issue

测试

文档更新

类型标签

likedislike
Pull Request has been successfully merged by CANN-robot.
(Thank you for liuliu876's contribution.)
liuliu876liuliu876Collaborators
Oct 23 Created pull request, commit e1e5617d
atomgit-bot
atomgit-bot
Oct 23 Comments:

变更摘要

本 PR 将 pre-commit 中的 OAT(Open Source Audit Tool)合规性检查从本地脚本模式切换为远程 hook 模式:在 .pre-commit-config.yaml 中把原来的 local + language: system 的 oat-check hook 替换为引用远程仓库 https://gitcode.com/HiAgent/compliance(rev: v1.0.6)的 Python hook,并删除了自维护的 scripts/oat_check.sh 脚本,从而把检查逻辑与版本维护交给外部仓库管理。

主要改动

  • OAT 检查切换为远程 hook: .pre-commit-config.yaml 中 oat-check 的 repo 由 local 改为远程地址 https://gitcode.com/HiAgent/compliance,并固定 rev: v1.0.6,实现检查逻辑外部化与版本锁定。
  • 移除本地执行方式配置: 删除了该 hook 的 name、entry: bash scripts/oat_check.sh、language: system 与 types: [file] 字段,执行入口改由远程 hook 自身提供,保留 pass_filenames、stages: [pre-commit]、verbose: true。
  • 删除自维护检查脚本: 移除 scripts/oat_check.sh(整文件删除),不再需要在仓库内维护 Python 解释器探测、oat-py 安装/升级、文件收集与报告解析等逻辑。

(本次改动仅涉及上述两个文件,未包含文档或测试相关变更。)

likedislike
Incorrect?
atomgit-bot
atomgit-bot
Oct 23 Comments:

代码审查

✅ 未发现问题

likedislike
Incorrect?
liuliu876liuliu876Collaborators
Oct 23 Modify description of pull request
CANN-robotCANN-robotCollaborators
Oct 23 Added label: cann-cla/yes
CANN-robot
CANN-robotCollaborators
Oct 23 Comments:

Thanks for your pull-request.
The full list of commands accepted by me can be found at here.
You can get sig-info at here.
You can self-configure the PR merge rules for this repository. For more details, please refer to Here.
For more, you also can visit HICANN.


PR Approval Progress

✅ Congratulations! All modules have met the lgtm and approve requirements.

Module Approval Details

module lgtm status approve status
repo-cann/asc-devkit ✅ 诸葛洵, chentianyu19 (2/2) ✅ 诸葛洵, chentianyu19 (2/1)
scripts ✅ 诸葛洵, chentianyu19 (2/2) ✅ 诸葛洵 (1/1)

💡 Tip:

  • Committer can comment /approve or /lgtm
  • Commenting /approve implies both code review (lgtm) and intent to merge (approve)

CLA Signature Pass

liuliu876, thanks for your pull request. All authors of the commits have signed the CLA. 👍

likedislike
CANN-robotCANN-robotCollaborators
Oct 23 Set zengjuan,zhanghao_0689,suqwe,kevin365,wulinyu,kong0808,dengjing_aoe,YeZZzzz1,bluesky901,yangbinhua,zhudi22,chenyiyuan,xun_zhuge,XuebinYang,sjtulxh,bianque,houyuyang,Lycheeeee,YANXI_ZHAO,chentianyu19,shi_nanxiang,wuyang_hw,jiangxinyu3,ascendhjh,hujiawen_kaven,wangxiaozhi,DragonBornHD84,louyuxuan,hyolee,yukangchen as approver
CANN-robotCANN-robotCollaborators
Oct 23 Set zengjuan,zhanghao_0689,suqwe,kevin365,wulinyu,kong0808,dengjing_aoe,YeZZzzz1,bluesky901,yangbinhua,zhudi22,chenyiyuan,xun_zhuge,XuebinYang,sjtulxh,bianque,houyuyang,Lycheeeee,YANXI_ZHAO,chentianyu19,shi_nanxiang,wuyang_hw,jiangxinyu3,ascendhjh,hujiawen_kaven,wangxiaozhi,DragonBornHD84,louyuxuan,hyolee,yukangchen as approver
liuliu876liuliu876Collaborators
Oct 23 Associated issue: [pre-commit检查切换]: 将 OAT 检查切换为远程 pre-commit hook模式
liuliu876
liuliu876Collaborators
Oct 23 Comments:

compile

likedislike
liuliu876liuliu876Collaborators
Oct 23 Pre merge succeeded (commit_id: fc091ed2e0523dce541b7ae158cccfb5899243b4)
CANN-robot
CANN-robotCollaborators
Oct 23 Comments:
🚀 CI 流水线已启动
📋 执行详情: 点击查看流水线
likedislike
CANN-robotCANN-robotCollaborators
Oct 23 Added label: ci-pipeline-running
zhugexun_sjtu
zhugexun_sjtuCollaborators
Oct 23 Comments:

/approve
/lgtm

likedislike
CANN-robotCANN-robotCollaborators
Oct 23 Added label: approved
chentianyu19
chentianyu19Collaborators
Oct 23 Comments:

/lgtm
/approve

likedislike
CANN-robotCANN-robotCollaborators
Oct 23 Added label: lgtm
CANN-robotCANN-robotCollaborators
Oct 23 Removed label: ci-pipeline-running
CANN-robotCANN-robotCollaborators
Oct 23 Added label: ci-pipeline-passed
CANN-robotCANN-robotCollaborators
Oct 23 Closed associated issue
CANN-robotCANN-robotCollaborators
Oct 23 Merged pull request