feat: add regression-test-missing action and pr-checks (composite action + parallel workflow)#46
feat: add regression-test-missing action and pr-checks (composite action + parallel workflow)#46Svtter wants to merge 11 commits into
Conversation
|
可合并 总结该 PR 新增了两个 composite action: 阻塞项无 建议项
|
|
发现遗漏 摘要对比 Issue #45 规范与 PR 实现,发现 1 个 CRITICAL、1 个 MEDIUM、2 个 LOW 级别的遗漏。核心问题在于 CRITICAL1.
MEDIUM2. README 文档未更新
LOW3. 未创建
4.
|
|
发现遗漏 摘要对比 Issue #45 规范与 PR 实现,发现 1 个 CRITICAL、1 个 MEDIUM、2 个 LOW 级别的遗漏。 CRITICAL1.
MEDIUM2. pr-checks 未实现跨 job 缓存共享(方案 C)
LOW3. 缺少对
4.
|
|
可合并 总结该 PR 新增了 阻塞项无 建议项
|
|
发现遗漏 摘要对比 Issue #45 规范与 PR 实现,发现 1 个 CRITICAL、1 个 MEDIUM 级别的遗漏。核心问题: CRITICAL1.
MEDIUM2.
补充说明(非遗漏)以下三项在前次 review 中被提及,经核实不构成遗漏:
|
|
无需回归测试 PR 类型: NEW_FEATURE 该 PR 仅新增了 |
|
现在我已经审阅了所有更改的文件。以下是完整审查意见: 有条件合并 总结PR 新增了 阻塞项1.
修复建议:源仓库 # regression-test-missing.yml
uses: ./regression-test-missing
# pr-checks.yml
uses: ./review
uses: ./feature-missing
uses: ./regression-test-missing消费者拷贝时可自行改为 建议项1. 输入顺序与
2.
3. README line 202 中的表述
其中 4. 超过 40 行的 prompt 直接嵌入 action.yml 增加了文件复杂度。建议抽取到独立文件(如 |
|
可合并 总结PR 新增 阻塞项无 建议项
|
|
发现遗漏 摘要对比 Issue #45 规范与 PR 实现,发现 1 个 CRITICAL、1 个 MEDIUM 级别的遗漏。 CRITICAL1.
MEDIUM2.
|
|
发现遗漏 摘要对比 Issue #45 规范与 PR 实现,发现 1 个 CRITICAL、1 个 MEDIUM、1 个 LOW 级别的遗漏。 CRITICAL1.
MEDIUM2.
LOW3.
说明:以下前次 review 提及的问题经核实不构成遗漏
|
|
现在我已完成审核。以下是结论: 可合并 该 PR 新增了 阻塞项:无 建议项:
|
|
无需回归测试 PR 类型: NEW_FEATURE 该 PR 仅新增了 |
|
无需回归测试 PR 类型: NEW_FEATURE 该 PR 纯新增 |
|
发现遗漏 摘要对比 Issue #45 规范与 PR 实现,发现 1 个 MEDIUM、1 个 LOW 级别的遗漏。 MEDIUM1.
LOW2.
|
|
可合并 该 PR 新增了 阻塞项:无 建议项:
|
|
发现遗漏 摘要对比 Issue #45 规范与 PR 实现,发现 1 个 MEDIUM、1 个 LOW 级别的遗漏。 MEDIUM1. 跨 job 缓存共享(方案 C)未实现
LOW2.
|
|
现在我已完整阅读了所有变更文件。以下是审查结论: 可合并 总结PR 新增了 阻塞项无 建议项
|
人工 Review 总结逐条审阅了所有 AI review comments 并去重后,归纳如下: ❌ 误报
✅ 确认需要关注的问题1. 跨 job 缓存共享(方案 C)未实现 — 被提及 7 次
2. 输入顺序不一致 — 被提及多次
3. prompt 逻辑重复
📝 文档 / 一致性(建议后续跟进)
|
Add two new composite actions: - regression-test-missing: detects PRs that fix bugs or modify behavior but lack corresponding regression tests - pr-checks: combines review, feature-missing, and regression-test-missing checks into a single opencode invocation Update ci.yml smoke test to cover both new actions. Closes #45
- Fix cache key prefix: use regression-test-missing-opencode- prefix - Fix version management: use setup-opencode/default-version instead of hardcoded value, matching review action pattern - Replace pr-checks composite action with proper workflow file containing 3 parallel jobs (review, feature-missing, regression-test-missing) - Add .github/workflows/regression-test-missing.yml standalone workflow - Remove pr-checks/ directory (now a workflow, not a composite action) - Update README with regression-test-missing docs and pr-checks workflow reference - Update ci.yml smoke test description
Workflow files referenced Svtter/opencode-actions/regression-test-missing@v2 which does not exist yet in the v2 tag. Use ./ local paths instead so they resolve from the PR branch during testing.
- Create pr-checks/action.yml composite action with combined prompt for single-invocation usage (users can reference via Svtter/opencode-actions/pr-checks@v2) - Keep .github/workflows/pr-checks.yml as parallel 3-job version - Add fork protection to regression-test-missing.yml - Unify checkout step names in pr-checks.yml - Add pr-checks smoke test to ci.yml
12de844 to
727ee27
Compare
|
无需回归测试 PR 类型: NEW_FEATURE 该 PR 纯新增功能:创建了 |
|
无需回归测试 PR 类型: NEW_FEATURE 该 PR 纯新增 |
|
可合并 总结PR 新增 阻塞项无 建议项
|
|
Author identity unknown *** Please tell me who you are. Run git config --global user.email "you@example.com" to set your account's default identity. fatal: empty ident name (for runner@runnervmrw5os.j2cb3q3zqujuhd1g3mgoi2ukia.bx.internal.cloudapp.net) not allowed |
|
发现遗漏 摘要对比 Issue #45 规范与 PR 实现,发现 1 个 MEDIUM、1 个 LOW 级别的遗漏。 MEDIUM1. 跨 job 缓存共享(方案 C)未实现
LOW2.
|
|
可合并 总结PR 新增 阻塞项阻塞项:无 建议项
|
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
无需回归测试 PR 类型: NEW_FEATURE 该 PR 纯新增功能:创建了 |
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
无遗漏 经过逐项比对 Issue #45 规范与 HEAD commit 的实现,所有需求均已完整交付: Deliverable 1 (regression-test-missing) — 完整实现:独立的 composite action,PR 类型分类(BUGFIX/BEHAVIOR_CHANGE/NEW_FEATURE/CHORE),仅对 BUGFIX 和 BEHAVIOR_CHANGE 标记缺少回归测试,输出格式符合规范("无需回归测试"/"缺少回归测试"),提示词覆盖了所有审计场景。输入定义和环境变量映射与 Deliverable 2 (pr-checks) — 规范中"composite action 包含 3 个并行 job"存在技术矛盾(GitHub Actions 的 composite action 不支持并行 job),PR 通过两个交付物合理解决:
其他交付物 — 独立 workflow
|
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
可合并 总结PR 新增 阻塞项阻塞项:无 建议项
|
|
无遗漏 分析逐项比对了 Issue #45 规范与 PR HEAD commit ( Deliverable 1 —
Deliverable 2 —
其他交付物 ✅
说明: |
…sion-test-missing - Add regression-test-missing and pr-checks steps to smoke-test.yml - Add extra-env input to regression-test-missing/action.yml for consistency with pr-checks - Improve git identity comment in regression-test-missing workflow
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
无需回归测试 PR 类型: NEW_FEATURE 该 PR 纯新增功能:创建了 |
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
可合并 总结PR 新增
阻塞项:无 建议项
|
|
无需回归测试 PR 类型: NEW_FEATURE 该 PR 纯新增功能:创建了 |
|
All spec requirements from Issue #45 have been verified against the implementation. Here is the complete analysis: 无遗漏 分析逐一比对 Issue #45 规范与 HEAD commit 的实现,所有需求均已完整交付: Deliverable 1:
|
| 规范要求 | 实现位置 | 状态 |
|---|---|---|
| PR 类型分类(BUGFIX / BEHAVIOR_CHANGE / NEW_FEATURE / CHORE) | regression-test-missing/action.yml:105-109 prompt |
✅ |
| 仅对 BUGFIX 和 BEHAVIOR_CHANGE 标记缺少回归测试 | regression-test-missing/action.yml:111 |
✅ |
| 输出格式:"无需回归测试" / "缺少回归测试" + 中文分析 + severity 分级 | regression-test-missing/action.yml:129-139 |
✅ |
Version 从 default-version 文件读取 |
regression-test-missing/action.yml:170-189 |
✅ |
缓存键前缀统一(regression-test-missing-opencode-) |
regression-test-missing/action.yml:228 |
✅ |
reasoning-effort / enable-thinking / extra-env 输入及 env 映射 |
regression-test-missing/action.yml:77-91,255-257 |
✅ |
GITHUB_RUN_OPENCODE_PERMISSION 安全限制 |
regression-test-missing/action.yml:261-262 |
✅ |
| 所有 API key / prompt / model env 变量正确传递到 Python 脚本 | regression-test-missing/action.yml:241-262 |
✅ |
Deliverable 2: pr-checks/ 整合交付
Spec 要求 "composite action 内 3 个并行 job 分别调用独立 action" 在 GitHub Actions 中技术上不可行(composite 不支持并行 job)。PR 拆分为两个交付物合理解决:
| 交付物 | 规范要求 | 实现 | 状态 |
|---|---|---|---|
pr-checks/action.yml |
可通过 uses: 引用的 composite action |
combined prompt 方式,单次 sequential opencode 调用完成三个检查 | ✅ |
.github/workflows/pr-checks.yml |
3 并行 job + 跨 job 缓存共享(方案 C) | setup job → 3 check jobs via needs: [setup],共享 install-dir/xdg-cache-home outputs |
✅ |
| 各 job 调用独立 composite action | review job → ./review, feature-missing → ./feature-missing, regression-test-missing → ./regression-test-missing |
✅ | |
| 跨 job 缓存共享 | setup job 先安装缓存,后续 job 复用 install-dir/xdg-cache-home 路径 |
✅ |
pr-checks/action.yml 环境变量完整性检查:
- 所有 19 个
GITHUB_RUN_OPENCODE_*环境变量(从 working-directory 到 permission)均已映射 ✅
其他交付物
| 交付物 | 状态 |
|---|---|
.github/workflows/regression-test-missing.yml 独立 workflow(含 fork 保护、git identity) |
✅ |
.github/workflows/ci.yml smoke test 覆盖 regression-test-missing + pr-checks(第 64-82 行) |
✅ |
.github/workflows/smoke-test.yml 覆盖两个新 action(第 40-56 行) |
✅ |
README.md:What it includes 列表(第 36 行) |
✅ |
README.md:regression-test-missing 专节 + 四种 action 对比表(第 124-149 行) |
✅ |
README.md:Usage 列表含 regression-test-missing@v2 和 pr-checks@v2(第 204-205 行) |
✅ |
README.md:CI 描述含新 action(第 240 行) |
✅ |
README.md:Publishing Checklist(第 255 行) |
✅ |
run-github-opencode.py:reasoning-effort 输入校验增强(+3 行) |
✅ |
所有 Acceptance Criteria 均满足:regression-test-missing 可独立使用、pr-checks.yml 可并行运行三个检查、prompt 逻辑正确区分 PR 类型、遵循 review/feature-missing 的架构模式。
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
可合并 总结PR 新增 阻塞项阻塞项:无 建议项
|
|
根据对 Issue #45 规范和 HEAD commit 无遗漏 分析Deliverable 1:
|
… type check - Fix copy-paste error: feature-missing description changed from 'spec coverage audit' to 'PR scope audit' - Add pr-checks@v2 to usage guide - Add type validation for GITHUB_RUN_OPENCODE_PERMISSION JSON input
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
无需回归测试 PR 类型: NEW_FEATURE 该 PR 纯新增 |
|
Now I have a complete picture of the current HEAD ( 可合并 总结PR 新增 阻塞项阻塞项:无 建议项
|
|
无需回归测试 PR 类型: NEW_FEATURE 该 PR 纯新增 |
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
无遗漏 分析逐项比对 Issue #45 规范与当前 HEAD 实现,所有可实现的需求均已完整交付。 Deliverable 1:
|
|
remote: Permission to sun-praise/opencode-actions.git denied to github-actions[bot]. |
|
无遗漏 分析逐项比对 Issue #45 规范与 PR HEAD commit ( Deliverable 1 —
Deliverable 2 —
其他交付物 ✅
所有 Acceptance Criteria 均满足。Spec 中 "composite action 内含 3 个并行 job" 属于 GitHub Actions 能力限制导致的规范内在矛盾,PR 通过两个交付物正确应对。 |
|
Now I have a complete picture. Let me compile my review. 可合并 该 PR 新增 阻塞项:无 建议项:
|






































Summary
Closes #45
1.
regression-test-missing/composite actionStandalone action that detects PRs fixing bugs or modifying behavior without regression tests.
无需回归测试or缺少回归测试2.
pr-checks/composite actionSingle-invocation action with a combined prompt that runs all three checks (review, feature-missing, regression-test-missing) in one opencode call. Users can reference via
uses: Svtter/opencode-actions/pr-checks@v2.3.
.github/workflows/pr-checks.ymlparallel workflowAlternative: 3 parallel jobs (review, feature-missing, regression-test-missing) each calling the corresponding independent composite action.
4.
.github/workflows/regression-test-missing.ymlstandalone workflow5. Updated
ci.ymlsmoke test and READMEFiles
regression-test-missing/action.ymlpr-checks/action.yml.github/workflows/regression-test-missing.yml.github/workflows/pr-checks.yml.github/workflows/ci.ymlREADME.md