fix: update stale docs, action yaml validation, and promote design skills#950
Conversation
…ills docs/review/troubleshooting.md: - Update exec --plan note: PR #935 (v0.68.0) now invokes generateReview, findings are real (not always []) docs/development/execution-context-contract.md: - Add PR #935 addenda to replay contract section (Stage 3 now invoked) pages/reference/plangate-cli-roadmap.md: - Mark public entrypoint row as implemented (v0.68.0+); review plan/exec/verify are wired in src/cli.mjs runners/github-action/action.yml: - Fix output_format validation regex: add yaml to allowed values (documented but previously rejected) skills: promote design-token-enforcement and design-system-component-reuse - Add golden outputs for all 4 fixtures (rubric verified) - Flip recommended: false → true in registry.yaml Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
River Reviewer
選択されたスキル (0)
スキップされたスキル (90)
優先度サマリー
スコア (参考値)結果(スコア): 96/100 内訳:
指摘
|
There was a problem hiding this comment.
Code Review
本プルリクエストでは、--plan リプレイ機能の仕様変更に伴うドキュメントの更新、メインCLIのロードマップ更新、GitHub Actionへの yaml 出力フォーマットの追加、および新規デザインスキルの追加と有効化が行われています。レビューでは、GitHub Actionにおける yaml 出力時のPRコメント表示崩れや出力パス未定義の問題、およびゴールデンファイル内で非標準の TokenSuggestion: ラベルが使用されていることでパーサーが正常に動作しない懸念が指摘されており、これらへの対応が推奨されています。
| # Validate output format | ||
| output_fmt="${RIVER_OUTPUT_FORMAT}" | ||
| if [[ ! "${output_fmt}" =~ ^(text|markdown|json)$ ]]; then | ||
| if [[ ! "${output_fmt}" =~ ^(text|markdown|json|yaml)$ ]]; then |
There was a problem hiding this comment.
output_format に yaml が追加されましたが、現状のワークフローのロジックでは yaml 出力時にいくつかの問題が発生します。
- 誤った拡張子とPRコメントへの投稿:
output_fmt が json 以外の場合(yaml を含む)、出力は ${RUNNER_TEMP}/river-reviewer-comment.md に書き込まれ、Post PR comment ステップによってそのまま PR コメントとして投稿されてしまいます。YAML 形式のテキストがそのまま Markdown として投稿されると、インデントや記号(- や #)が Markdown のリストやヘッダーとして誤ってレンダリングされ、表示が崩れてしまいます。 - 出力パスの欠如:
JSON 出力時には json_path というアウトプットが提供されますが、YAML 出力時には yaml_path のような構造化データを後続ステップで利用するためのアウトプットが定義されていません。
推奨される修正案:
action.yml 全体で yaml を json と同様に構造化データとして扱い、PR コメントへの投稿をスキップし、yaml_path を出力するように変更することを検討してください。
| Finding: Hardcoded hex color `#3B82F6` used directly in inline style prop instead of a design token or CSS custom property. | ||
| Evidence: src/components/PrimaryButton.tsx:11 — `style={{ color: '#3B82F6', padding: '16px', fontSize: '14px' }}` | ||
| TokenSuggestion: Replace with Tailwind utility class `text-blue-500`, or CSS custom property `var(--color-primary)` if a semantic token exists in the project. | ||
| Severity: minor | ||
| Confidence: high | ||
|
|
||
| --- | ||
|
|
||
| Finding: Hardcoded pixel padding `'16px'` used in inline style prop instead of a spacing token. | ||
| Evidence: src/components/PrimaryButton.tsx:11 — `style={{ color: '#3B82F6', padding: '16px', fontSize: '14px' }}` | ||
| TokenSuggestion: Replace with Tailwind utility class `p-4` (which maps to 16px in the default Tailwind scale). | ||
| Severity: minor | ||
| Confidence: high | ||
|
|
||
| --- | ||
|
|
||
| Finding: Hardcoded font size `'14px'` used in inline style prop instead of a typography token. | ||
| Evidence: src/components/PrimaryButton.tsx:11 — `style={{ color: '#3B82F6', padding: '16px', fontSize: '14px' }}` | ||
| TokenSuggestion: Replace with Tailwind utility class `text-sm` (which maps to 14px in the default Tailwind scale), or `var(--font-size-sm)` if a CSS custom property exists in the project. | ||
| Severity: minor | ||
| Confidence: high |
There was a problem hiding this comment.
このゴールデンファイルでは TokenSuggestion: というカスタムラベルが使用されていますが、src/lib/review-engine.mjs のシステムプロンプトやパーサー(parseFindingMessage)が期待する標準のラベルは Fix: または Suggestion: です。
TokenSuggestion: を使用すると、パーサーが提案(suggestion)を正しく抽出できず、構造化データ(finding.suggestion)が null になってしまう可能性があります。
一貫性とパースの正確性を保つため、標準の Fix: または Suggestion: に変更することを推奨します。
PlanGate Review
PlanGate review decision: pass
ポリシー: critical=fail / major=fail-if-required (warn) / minor=comment-only / info=skipped — spec: |
Summary
Codex が指摘した3件を対応。
変更内容
ドキュメント陳腐化修正
docs/review/troubleshooting.md—exec --planが PR feat(cli): --plan replay execution wires generateReview (#878 A2-3-impl) #935 でgenerateReviewを呼ぶようになった事実を反映docs/development/execution-context-contract.md— replay contract の PR feat(cli): --plan replay execution wires generateReview (#878 A2-3-impl) #935 追補を追加(Stage 3 が実行される)pages/reference/plangate-cli-roadmap.md— 公開エントリポイント行を「未実装」→「実装済み v0.68.0+」に更新Action バグ修正
runners/github-action/action.yml—output_formatバリデーション正規表現にyamlを追加(ドキュメントに記載済みだが検証で弾かれていた)デザインスキル昇格
rr-midstream-design-token-enforcement-001— golden 4件生成、recommended: trueに昇格rr-midstream-design-system-component-reuse-001— golden 4件生成、recommended: trueに昇格Test plan
npm test— 1113 tests passskills:validate— pass🤖 Generated with Claude Code