Open
fix(security-committee): use a valid branch type for compliance-operator main #356
fix(security-committee): use a valid branch type for compliance-operator main #356
Open
pengxingangAdd on 19 days ago
pengxingang
pengxingang
19 days ago

问题背景

sig/README.md 为代码仓描述文件定义了两个不同的 type 字段:顶层仓库级(:96,枚举 public / private)与 branches 元素内的分支级(:103,枚举 protected / readonly)。

sig/security-committee/openfuyao/c/compliance-operator.yaml:6 把仓库级的 public 填进了分支级 type,是全部 125 个描述文件、175 个分支条目中唯一一个取该非法值的(其余为 protected 173 个、空值 1 个)。以该文件为输入的分支保护逻辑会拿到枚举外的值,main 分支不会按 sig/README.md:103 定义的「可以被发布版本集成」语义被登记为 protected。

关联 Issue

https://gitcode.com/openFuyao/community/issues/12

PR 类型

变更描述

单文件单行,sig/security-committee/openfuyao/c/compliance-operator.yaml(+1 / -1):

@@ -3,4 +3,4 @@ type: public
 description: '安全扫描Operator,支持CIS、 STIG规则扫描'
 branches:
   - name: main
-    type: public
+    type: protected

顶层 :2 的 type: public(仓库级,合法)保持不变;:5 的 - name: main 也不变(已实测 openFuyao/compliance-operator 真实存在 main 分支)。

发布说明

NONE

测试验证

本仓无 CI 工作流,门禁为本地 YAML 校验与全仓枚举统计。

1) 用「禁止重复键」的 yaml loader 解析本文件 -> OK,exit 0

2) 遍历全部 125 个 sig/*/openfuyao/*/*.yaml,统计 branches[].type 取值
   master (7cb7690):  {'protected': 173, 'None': 1, 'public': 1}
   本分支       :  {'protected': 174, 'None': 1}
   -> 非法值 public 归零;剩下的 None 属 ray-image-builder(空仓,另案)

对照复核:

cat sig/security-committee/openfuyao/c/compliance-operator.yaml
cat sig/security-committee/openfuyao/c/common.yaml

改完后两个文件的 branches 段完全同构(- name: main / type: protected),与同 SIG 其余描述文件一致。

文件末尾原有的「无换行符」状态被原样保留(diff 两侧都是 \ No newline at end of file),未引入无关的行尾变更。

影响范围与回滚

  • 只改一个 YAML 标量值,不改结构、不改键名、不改缩进、不改分支名。
  • 影响面限于 openFuyao/compliance-operator 的 main 分支保护登记。
  • 无代码、无工具、无流水线变更。
  • 回滚:单 commit,git revert 即可。

备注

  • 基于 origin/master(7cb7690)创建分支 fix/compliance-operator-branch-type,单 commit 05fbf6a。
  • 与本仓 4 个 open PR 文件面不重叠。特别说明:!331 正在改 sig/sig-security-committee 的 sig-info.yaml,本 PR 改的是同 SIG 下的代码仓描述文件 openfuyao/c/compliance-operator.yaml,两者不是同一个文件,不会冲突;本 PR 也刻意没有触碰 sig-info.yaml。
  • 未顺手给该文件补末尾换行,也未处理 ray-image-builder.yaml 的空 name/type(后者因目标仓为空仓、正确值无从推断,已在 Issue 中说明)。

AI 使用声明

  • 辅助工具:Trae(AI 编码助手)
  • 参与环节:全仓 125 个代码仓描述文件的字段与枚举值普查、sig/README.md 两级 type 枚举的口径比对、目标仓真实分支的联网核对、YAML 校验执行与结果记录

人工复核声明

likedislike
Merge blocked
pengxingangpengxingang
19 days ago Associated issue: compliance-operator.yaml 的分支级 type 误用了仓库级枚举值 public
openFuyao-botopenFuyao-botCollaborators
19 days ago Added label: sig/sig-Tc
openFuyao-bot
openFuyao-botCollaborators
19 days ago Comments:

欢迎来到 openFuyao 社区

Hey @peng_xingang , 感谢你对社区的贡献.

机器人使用手册

有关指令的使用,可以点击 此处 查看详情。开发人员可以在每个PR或Issue下方评论特定指令来触发机器人任务。您可以自助配置此仓库的 PR 合并规则,更多详情,请参阅此处。

联系指引

有疑问可以联系 SIG: sig-Tc ,
维护者是: @chenchuanyu, @foxbit, @huhao-of, @yaoxiaozhong, @zhangweitao ,
审核者是: @javadoors, @zhangxyjlu .

likedislike
openFuyao-botopenFuyao-botCollaborators
19 days ago Added label: openFuyao-cla/yes
pengxingang
pengxingang
19 days ago Comments:

cc @zhangxyjlu @chenchuanyu 请评审。

关联 Issue:https://gitcode.com/openFuyao/community/issues/12

改动范围:peng_xingang:fix/compliance-operator-branch-type 上的单 commit,涉及文件与逐行 diff 见 PR 正文「变更描述」;本地门禁输出见「测试验证」。

PR 正文末尾的「人工复核声明」4 项按模板要求保持未勾选,由我人工确认后勾选。
本 PR 由 AI 辅助完成分析与草稿,已在「AI 使用声明」中如实标注。

likedislike
pengxingangpengxingang
7 days ago Force-pushed 3 commits:22b4e749-2 commits from branch master,91cf3346-fix(security-committee): use a valid branch type for compliance-operator main
openFuyao-botopenFuyao-botCollaborators
7 days ago Removed label: openFuyao-cla/yes
openFuyao-botopenFuyao-botCollaborators
7 days ago Added label: openFuyao-cla/yes
openFuyao-bot
openFuyao-botCollaborators
7 days ago Comments:

CLA 签署成功

peng_xingang, 感谢您的代码贡献。 所有的代码贡献者都已完成了 CLA 签署。 👍

likedislike
pengxingang
pengxingang
7 days ago Comments:

/retest

likedislike