Skip to content

HYP-151: make lint に Ruff を含める#417

Open
proboscis wants to merge 3 commits into
mainfrom
reactor/doeff-impl-pr-human-review-hyp-151
Open

HYP-151: make lint に Ruff を含める#417
proboscis wants to merge 3 commits into
mainfrom
reactor/doeff-impl-pr-human-review-hyp-151

Conversation

@proboscis
Copy link
Copy Markdown
Owner

@proboscis proboscis commented May 24, 2026

概要

make lint を全 lint の入口として扱う既存の説明に合わせ、root の lint target から lint-ruff を実行するようにしました。あわせて make -n lint の展開結果に root の Ruff 実行が含まれることを固定する検査を追加しています。

PR説明図

変更内容

  • Makefilelint target に lint-ruff を追加しました。
  • tests/test_makefile_lint_contract.py を追加し、make -n lintuv run ruff check doeff/ tests/ packages/ が含まれることを検査します。
  • PR 説明図を Hypha/Evidence/HYP-151/pr-explanation.png に追加し、imagegen prompt を隣に保存しました。
  • 差し戻し理由だった英語説明ラベルを避けるため、PR 説明図を日本語ラベル中心の内容に更新しました。
  • 最新 main を通常 merge で取り込み、PR head を現在の base に追従させました。

確認

  • uv run pytest tests/test_makefile_lint_contract.py 通過
  • uv run ruff check tests/test_makefile_lint_contract.py 通過
  • make -n lint で root の uv run ruff check doeff/ tests/ packages/ が表示されることを確認
  • git diff --check origin/main...HEAD 通過
  • make lint-ruff は既存の Ruff 指摘 1634 件で失敗することを確認しました。今回の追加検査自体は個別 Ruff を通過しています。

レビュアー向け注意

非 UI 変更のため、画面証跡は不要です。レビューでは make lint の契約を Ruff 必須に戻す判断と、既存 Ruff 指摘の扱いを確認してください。

@proboscis
Copy link
Copy Markdown
Owner Author

config-effects 確認結果: 対象外です。

PR #417 の現在 head 97a77f42287197afd7cb9379e6efc8e991ee3856 の差分を確認しました。変更は Makefile の lint target、tests/test_makefile_lint_contract.py、PR 説明図のみで、実行時設定の注入、環境変数読み取り、Ask / ask、interpreter、defp / defpp / defk の境界には触れていません。

そのため、この review round の config-effects check は not_applicable として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

doeff Hy style 確認: 対象外です。

現在の PR head 97a77f42287197afd7cb9379e6efc8e991ee3856 の差分を確認したところ、変更ファイルは Makefiletests/test_makefile_lint_contract.pyHypha/Evidence/HYP-151/pr-explanation.* のみで、.hy / .hyk / .hyp および生成 Hy コードの変更はありません。

このため defn / defk / defp / defpp の使い分けに関する指摘はなく、doeff-hy-stylenot_applicable として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

UI 証跡確認

結論: この PR は UI、画面表示、表示文言、ナビゲーション、スクリーンショットで確認する状態を変更していないため、UI 証跡確認は対象外です。

確認したこと:

  • 現在の PR head は 97a77f42287197afd7cb9379e6efc8e991ee3856 です。
  • 差分は Makefiletests/test_makefile_lint_contract.pyHypha/Evidence/HYP-151/pr-explanation.* のみです。
  • pr-explanation.png は PR 説明図であり、UI 証跡として扱う対象画面ではありません。

結果: ui-evidencenot_applicable として記録します。

Copy link
Copy Markdown
Owner Author

結論: code-review は通過で見ます。PR #417 は base が main で、make lint に root の lint-ruff 経路を戻す変更と、その経路を make -n lint で固定するテストが HYP-151 の範囲に合っています。

確認したこと:

  • Makefilelint target が lint-rufflint-pyrightlint-semgreplint-doefflint-packages を実行する構成になっていること。
  • make -n lintuv run ruff check doeff/ tests/ packages/ が root の make lint 経路に含まれること。
  • uv run pytest tests/test_makefile_lint_contract.py が通過すること。
  • uv run ruff check tests/test_makefile_lint_contract.py が通過すること。
  • 全体の uv run ruff check doeff/ tests/ packages/ --statistics は既存指摘で失敗しますが、今回追加されたテスト自体は Ruff clean で、PR は検査経路の復旧にスコープを絞れていること。

補足: 手元の全体 Ruff 統計では現在 1638 件だったため、PR 本文や説明図の「1640 件」は最終更新時に数字がずれる可能性があります。修正必須ではありませんが、最終説明では「既存指摘多数」のようにすると保守しやすいです。

@proboscis
Copy link
Copy Markdown
Owner Author

設計方針確認(core-philosophy): 対象外として記録します。

確認した現行 PR head: 97a77f42287197afd7cb9379e6efc8e991ee3856

この PR の変更ファイルは以下のみでした。

  • Makefile
  • tests/test_makefile_lint_contract.py
  • Hypha/Evidence/HYP-151/pr-explanation.png
  • Hypha/Evidence/HYP-151/pr-explanation.imagegen-prompt.md

reactor/reactor/hypha_adapters/、WebUI 投影、workflow / reconciliation / review dispatch、architecture review dispatch、runtime launch / session code には触れていません。そのため、Reactor core に project 固有の reviewer policy、agent id、workflow id、HYP 固有 artifact rule、imagegen gate、固定 review-check matrix を追加していないと判断し、このチェックは対象外です。

@proboscis
Copy link
Copy Markdown
Owner Author

PR説明図確認: 修正が必要です。

validator は current head 97a77f42287197afd7cb9379e6efc8e991ee3856Hypha/Evidence/HYP-151/pr-explanation.png と imagegen prompt 証跡を確認できており、PNG / URL / head pinning は通っています。生成元を示す prompt 証跡と、余計な図面 sidecar がないことも確認しました。

ただし、図中に subpackage lint という英語の説明ラベルが残っています。これは Makefile の exact target ではなく、下段の「subpackage lint だけに頼らない」も説明文なので、この check の「図内の見出し・ラベル・説明文は日本語、技術識別子のみ例外」という契約では通せません。

imagegen skill で図を再生成し、該当箇所を日本語の「サブパッケージの lint」などに置き換えるか、識別子として必要なら正確な lint-packages target を使ってください。

@proboscis
Copy link
Copy Markdown
Owner Author

doeff-hy-style 確認結果: 対象外です。

現在の PR head 4843a8794c087b2734c37466aefee7a3b1c02b82 の差分を確認しました。変更ファイルは Makefiletests/test_makefile_lint_contract.pyHypha/Evidence/HYP-151/pr-explanation.* のみで、.hy / .hyk / .hyp や生成 Hy コードは変更されていません。

そのため、今回の defn / defk / defp / defpp スタイル確認は not_applicable として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

config-effects 確認結果: 対象外です。

現在 head 4843a8794c087b2734c37466aefee7a3b1c02b82 の差分は Makefile の lint target、tests/test_makefile_lint_contract.py、PR 説明図とその prompt 証跡のみでした。設定注入、環境変数読み、Ask / asklazy_ask、interpreter / handler / Program entrypoint 境界には触れていません。

確認したこと:

  • git diff --name-status origin/main...HEAD で変更ファイルを確認
  • 差分内に os.environAskasklazy_askdefkdefpdefppProgram、interpreter などの設定/effect 境界に関わる変更がないことを確認
  • uv run pytest tests/test_makefile_lint_contract.py 通過
  • make -n lint で root Ruff 経路を確認

このため、この review check は not_applicable として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

結論: code-review は通過です。PR #417 は base が main で、HYP-151 の範囲どおり root の make lint 経路へ lint-ruff を戻しています。

確認したこと:

  • Makefilelint target が lint-rufflint-pyrightlint-semgreplint-doefflint-packages を順に呼ぶ構成になっていること。
  • tests/test_makefile_lint_contract.pymake -n lint の展開結果に root Ruff 実行コマンドが含まれることを固定していること。
  • 非 UI 変更であり、画面証跡の有無はこの code-review では確認対象外であること。

実行した確認:

  • uv run pytest tests/test_makefile_lint_contract.py は通過しました。
  • uv run ruff check tests/test_makefile_lint_contract.py は通過しました。
  • make -n lintuv run ruff check doeff/ tests/ packages/ が表示されることを確認しました。
  • git diff --check origin/main...HEAD は通過しました。
  • root 全体の Ruff は既存指摘 1638 件で失敗することも確認しました。この PR は lint 経路の契約修正に絞っており、既存指摘の一括修正は別判断でよいと見ています。

@proboscis
Copy link
Copy Markdown
Owner Author

doeff-hy-style 確認結果: 対象外です。

現在の PR head 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a で変更ファイルを確認し、.hy / .hyk / .hyp または生成 Hy コードの追加・変更・削除はありませんでした。

確認した内容:

  • gh pr view 417 --json files,headRefOid で変更ファイルが Makefiletests/test_makefile_lint_contract.pyHypha/Evidence/HYP-151/... のみであることを確認しました。
  • git diff --name-only origin/main...HEAD -- "*.hy" "*.hyk" "*.hyp" は空でした。

このため、defn / defk / defp / defpp のスタイル確認は not_applicable として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

config-effects 確認結果: 対象外です。

最新 head 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a の差分は Makefilelint target、tests/test_makefile_lint_contract.py、PR 説明図だけで、実行時設定の注入、環境変数読み込み、interpreter、Ask / askdefk / defp / defpp の境界には触れていません。

このため config-effects は not_applicable として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

結論: 設計方針確認は対象外です。PR #417 は Reactor core / review dispatch / projection code を変更していません。

確認した差分:

  • Makefile: root lint target に lint-ruff を含める変更
  • tests/test_makefile_lint_contract.py: make -n lint の contract test
  • Hypha/Evidence/HYP-151/pr-explanation.png: PR 説明図
  • Hypha/Evidence/HYP-151/pr-explanation.imagegen-prompt.md: 説明図 prompt 証跡

設計方針確認の観点:

  • reactor/reactor/hypha_adapters/、WebUI projection、workflow / reconciliation / review dispatch、architecture review dispatch、runtime launch / session code への変更はありません。
  • project-specific reviewer policy、agent id、workflow id、HYP 固有 artifact rule、固定 review-check matrix を core に追加していません。

判定: not_applicable
PR head: 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a

Copy link
Copy Markdown
Owner Author

UI 証跡確認: 対象外です。

現在の PR head 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a で差分を確認しました。変更は Makefile の lint target、tests/test_makefile_lint_contract.py、PR 説明図 PNG と imagegen prompt 証跡に限られ、画面、レイアウト、ナビゲーション、スクリーンショットで確認すべき状態、ユーザー向け表示文言の変更はありません。

Hypha/Evidence/HYP-151/pr-explanation.png は PR 説明図であり、UI 証跡確認の対象ではありません。そのため validate-ui-evidence は実行せず、ui-evidencenot_applicable として記録します。

Copy link
Copy Markdown
Owner Author

結論: code-review は通過です。PR #417 は base が main で、HYP-151 の範囲どおり root の make lint 経路へ lint-ruff を戻し、その経路を focused test で固定できています。

確認したこと:

  • Makefilelint target が lint-rufflint-pyrightlint-semgreplint-doefflint-packages を呼ぶ構成になっていること。
  • tests/test_makefile_lint_contract.pymake -n lint の展開結果に root Ruff 実行コマンドが含まれることを検査していること。
  • PR 本文は非 UI 変更として説明されており、画面証跡や PR 説明図の詳細確認は別 check の担当範囲であること。

実行した確認:

  • uv run pytest tests/test_makefile_lint_contract.py は通過しました。
  • uv run ruff check tests/test_makefile_lint_contract.py は通過しました。
  • make -n lintuv run ruff check doeff/ tests/ packages/ が表示されることを確認しました。
  • git diff --check origin/main...HEAD は通過しました。
  • root 全体の Ruff 統計では既存指摘 1634 件が残っています。この PR は lint 経路の契約修正にスコープを絞れており、既存指摘の一括修正は別作業として扱う判断でよいと見ています。

@proboscis
Copy link
Copy Markdown
Owner Author

PR 説明図確認: 通過です。

確認結果:

  • PR 本文の ![PR説明図](...) は現在の PR head 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8aHypha/Evidence/HYP-151/pr-explanation.png を指しています。
  • review-check validate-pr-diagramdiagrams=1 valid=1 で通過しました。
  • Hypha/Evidence/HYP-151/ には説明図 PNG と pr-explanation.imagegen-prompt.md の組だけがあり、prompt 証跡には Tool: imagegenPrompt: が含まれています。
  • 図の可視テキストは日本語中心で、英語は make lintlint-ruffRuffMakefile など必要な技術識別子に限られています。
  • 図の内容は、この PR の Makefile の lint 依存追加と tests/test_makefile_lint_contract.py の経路検査に対応しています。

この確認は PR 説明図の契約だけを対象にしています。

@proboscis
Copy link
Copy Markdown
Owner Author

設定・effect 境界確認: 対象外です。

確認した範囲:

  • 現在の PR head は 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a です。
  • 差分は Makefiletests/test_makefile_lint_contract.pyHypha/Evidence/HYP-151/pr-explanation.* に限られています。
  • Ask / ask / lazy_ask / defk / defp / defpp / interpreter / 実行時設定読み込み / os.environ の境界変更はありません。

このため config-effectsnot_applicable として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

doeff-hy-style 確認結果: 対象外です。

PR #417 の current head 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a を確認しました。変更ファイルは Makefiletests/test_makefile_lint_contract.pyHypha/Evidence/HYP-151/pr-explanation.pngHypha/Evidence/HYP-151/pr-explanation.imagegen-prompt.md のみで、.hy / .hyk / .hyp や generated Hy code の追加・変更はありません。

defn / defk / defp / defpp のスタイル判定対象がないため、not_applicable として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

結論: code-review は通過です。make lint に root の Ruff 検査が戻り、経路を固定する focused test も現在 head で通っています。

確認したこと:

  • PR HYP-151: make lint に Ruff を含める #417 は base main、draft のまま、merge 状態は CLEAN です。
  • Makefilelint target が lint-ruff を含み、make -n lintuv run ruff check doeff/ tests/ packages/ が表示されます。
  • tests/test_makefile_lint_contract.py は dry-run 展開で root Ruff 経路を固定しており、issue の範囲に合っています。
  • uv run pytest tests/test_makefile_lint_contract.pyuv run ruff check tests/test_makefile_lint_contract.pygit diff --check origin/main...HEAD は通過しました。

補足: make lint-ruff は現在 1634 件の既存 Ruff 指摘で失敗します。この PR は lint 経路の契約修正に絞っており、既存指摘の一括修正を含めない判断は人間レビュー側で確認してください。UI 証跡と PR 説明図の詳細判定は別 check に委ねます。

@proboscis proboscis marked this pull request as ready for review May 25, 2026 15:07
@proboscis
Copy link
Copy Markdown
Owner Author

設計方針確認(core-philosophy): 対象外です。

現在の PR head: 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a

確認した差分:

  • Makefile
  • tests/test_makefile_lint_contract.py
  • Hypha/Evidence/HYP-151/pr-explanation.png
  • Hypha/Evidence/HYP-151/pr-explanation.imagegen-prompt.md

この PR は root の make lint 経路とその回帰テスト、PR 説明図の証跡だけを変更しています。reactor/reactor/hypha_adapters/、WebUI projection、workflow / reconciliation / review dispatch、architecture review dispatch、runtime launch / session code には触れていません。

そのため、Reactor core を汎用の Source -> Event -> Trigger -> Action -> Invocation -> Projection runtime として保てているかを確認するこの check では、審査対象外として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

UI 証跡確認: 対象外です。

現在の PR head 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a の差分を確認しました。変更は Makefiletests/test_makefile_lint_contract.py、および Hypha/Evidence/HYP-151/pr-explanation.* の PR 説明図証跡に限られており、アプリ画面、レイアウト、ナビゲーション、スクリーンショットで確認すべき状態、表示文言の変更はありません。

そのため、この確認では UI 証跡画像は不要です。PR 説明図は別の説明図確認の対象であり、UI 変更の証跡としては扱っていません。

@proboscis
Copy link
Copy Markdown
Owner Author

PR説明図確認: 通過です。

  • 現在 head 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a の PR 本文に ![PR説明図](https://github.com/proboscis/doeff/raw/4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a/Hypha/Evidence/HYP-151/pr-explanation.png) が埋め込まれています。
  • review-check validate-pr-diagramdiagrams=1 valid=1 で通過しました。
  • Hypha/Evidence/HYP-151/pr-explanation.imagegen-prompt.mdTool: imagegenPrompt: を含み、禁止された SVG / HTML / Mermaid / slide 等の sidecar はありません。
  • 画像内の見出し・説明文は日本語で、英語は make lintlint-ruffRuffPyright など必要な技術識別子に限られています。
  • 図の内容は差分(Makefilelint target に lint-ruff を追加し、tests/test_makefile_lint_contract.pymake -n lint の Ruff 経路を固定)と一致しています。

この check は pass で記録します。

@proboscis proboscis marked this pull request as draft May 25, 2026 15:22
@proboscis
Copy link
Copy Markdown
Owner Author

config-effects 確認結果: 対象外です。

現在の PR head 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a で差分を確認しました。変更は Makefile の lint target、tests/test_makefile_lint_contract.py、PR 説明図証跡に限られており、実行時設定の注入、Ask / askdefk / defp / defpp、interpreter / handler 境界、os.environ の扱いには触れていません。

そのため、この PR では設定・effect 境界の確認は not_applicable として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

doeff-hy-style 確認結果: 対象外です。

current head: 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a

確認内容:

  • PR diff の変更ファイルは Makefiletests/test_makefile_lint_contract.pyHypha/Evidence/HYP-151/pr-explanation.pngHypha/Evidence/HYP-151/pr-explanation.imagegen-prompt.md です。
  • .hy / .hyk / .hyp の追加・変更・削除はありません。
  • 生成 Hy コードの変更も見当たらないため、defn / defk / defp / defpp のスタイル確認対象はありません。

この check は not_applicable として記録します。

@proboscis
Copy link
Copy Markdown
Owner Author

結論: code-review は通過でよいと判断しました。

確認したこと:

  • PR HYP-151: make lint に Ruff を含める #417 は open draft、base は main、現在の head でレビューしました。
  • 差分は Makefilelint target、make -n lint を固定する focused test、PR 説明図関連に限られています。
  • lint target は lint-ruff を先頭に含み、AGENTS.mdMakefile の「make lint が全 lint の入口」という説明と一致しています。
  • 追加テストは make -n lint の展開結果に uv run ruff check doeff/ tests/ packages/ が含まれることを固定しており、HYP-151 の受け入れ条件に沿っています。

確認結果:

  • uv run pytest tests/test_makefile_lint_contract.py: 通過
  • uv run ruff check tests/test_makefile_lint_contract.py: 通過
  • make -n lint: root Ruff 経路を確認
  • git diff --check origin/main...HEAD: 通過

補足:

  • uv run ruff check doeff/ tests/ packages/ は既存指摘 1634 件で失敗しますが、今回の差分由来ではなく、この PR は Ruff を標準入口に戻す契約修正として妥当です。
  • GitHub Checks はこのブランチでは報告なしでした。

@proboscis
Copy link
Copy Markdown
Owner Author

設計方針確認: 対象外です。

現在の PR head は 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a です。差分は次の範囲だけでした。

  • Makefile:65: root の lint target に lint-ruff を含める変更
  • tests/test_makefile_lint_contract.py:7: make -n lint 経路に root Ruff が含まれることの focused test
  • Hypha/Evidence/HYP-151/pr-explanation.png / Hypha/Evidence/HYP-151/pr-explanation.imagegen-prompt.md: PR 説明図と prompt 証跡

この PR は reactor/reactor/hypha_adapters/、WebUI projection、workflow / reconciliation / review dispatch、architecture review dispatch、runtime launch / session code に触れていません。Reactor core の Source -> Event -> Trigger -> Action -> Invocation -> Projection 境界に、project 固有の reviewer policy、agent id、workflow id、HYP 固有 artifact rule、imagegen gate、固定 review-check 行列も追加していません。

そのため core-philosophynot_applicable として記録します。

Copy link
Copy Markdown
Owner Author

PR説明図確認(pr-explanation-diagram): 通過です。

確認結果:

  • PR 本文の ![PR説明図](...) は現在の PR head 4e45b4a7dfe8ff8c796ca9b07deeb16ea7198a8a に固定され、Hypha/Evidence/HYP-151/pr-explanation.png を指しています。
  • review-check validate-pr-diagramdiagrams=1 valid=1 で通過しました。
  • Hypha/Evidence/HYP-151/pr-explanation.imagegen-prompt.mdTool: imagegenPrompt: があり、説明図用の余計な .svg / .html / .css / .pptx / .mmd / .drawio sidecar はありません。
  • 図中の見出し・説明ラベルは日本語で、英語表記は Makefilelint-ruffuv run ruff check doeff/ tests/ packages/ など必要な技術識別子に限られています。
  • 図の内容は Makefilelint target に lint-ruff を戻す変更と、tests/test_makefile_lint_contract.py による make -n lint 経路確認に対応しています。

この check では追加修正の要求はありません。

@proboscis proboscis marked this pull request as ready for review May 25, 2026 15:40
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