{"canonical_url":"https://engineer.company/ja/portfolio/found-the-hooks-and-the-gate-disagreeing/","content_markdown":"# フックと品質ゲートの不一致を発見\n\n同じ検査を行うという文書の記述に反し、コミットフックと品質ゲートが異なる検査を行っていたことを、一覧を比較するテストで発見。手動でしか動かなかった5個は履歴書の文章を検査するものだった。\n\n7月 2026\n\n**状況.** コミット前のフックと、任意実行の全品質ゲートがあった。文書はフックが全ゲートを実行し、すべて通らなければ履歴に入らないと記していたが、別ファイルの2一覧を手で維持し、比較していなかった。\n\n**課題.** 両方をプログラムで列挙して差で失敗させ、主張を検証へ変える必要があった。\n\n**行動.** フック設定とタスク定義から実際に呼ぶ検査を解決して比較すると、不一致だった。ゲートだけにある5検査は偶然でなく、実績を非人称に保つ文体、禁止語、言語間数値、表記、内容の綴りという、履歴書の文章を読むものだった。コードはすべて自動で守り、製品そのものである文章は記憶したときだけ守っており、想像と逆の露出だった。5つをフックへ入れ、うち2つをコミット予算に耐える速さへ改善し、比較テストを残して再びずれないようにした。意図を説明していた文書が、強制される事実を説明するものになった。\n\n**結果.** 同じ検査を実行することを実証し、文章の検査も毎コミットで動くようになった。内容増加とともにフック時間も増え、遅すぎれば迂回される地点があるため、この修正の寿命は検査の速さにかかっている。\n\n---\n\n- 役割: テスト・品質エンジニア\n- カテゴリー: [DevOps](https://advisory.engineer.company/ja/categories/devops/), [自動化・CI/CD](https://advisory.engineer.company/ja/categories/automation/), [テスト・品質保証](https://advisory.engineer.company/ja/categories/testing/), [Python](https://advisory.engineer.company/ja/categories/python/), [文書作成](https://advisory.engineer.company/ja/categories/documentation/)\n- サービス: [DevOps・CI/CD自動化](https://advisory.engineer.company/ja/services/devops-cicd/), [技術面の統率・コンサルティング](https://advisory.engineer.company/ja/services/technical-leadership/), [技術文書の作成](https://advisory.engineer.company/ja/services/technical-documentation/)\n\n\u003chttps://engineer.company/ja/portfolio/found-the-hooks-and-the-gate-disagreeing/\u003e\n","date_modified":"2026-11-09T21:50:25Z","description":"同じ検査を実行することを実証し、文章の検査も毎コミットで動くようになった。内容増加とともにフック時間も増え、遅すぎれば迂回される地点があるため、この修正の寿命は検査の速さにかかっている。","formats":{"gemtext":"https://advisory.engineer.company/ja/portfolio/found-the-hooks-and-the-gate-disagreeing/index.gmi","gopher":"https://advisory.engineer.company/ja/portfolio/found-the-hooks-and-the-gate-disagreeing/gophermap","html":"https://advisory.engineer.company/ja/portfolio/found-the-hooks-and-the-gate-disagreeing/","json":"https://advisory.engineer.company/ja/portfolio/found-the-hooks-and-the-gate-disagreeing/index.json","markdown":"https://advisory.engineer.company/ja/portfolio/found-the-hooks-and-the-gate-disagreeing/index.md","pdf":"https://advisory.engineer.company/ja/portfolio/found-the-hooks-and-the-gate-disagreeing/index.pdf"},"kind":"page","language":"ja","title":"フックと品質ゲートの不一致を発見","url":"https://advisory.engineer.company/ja/portfolio/found-the-hooks-and-the-gate-disagreeing/","version":1}