registrystack / registrystack/registry-stack

Feature-gate the Evidence relying-party dependency in registry-breg

オープン
#930 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
area:breg area:evidence criticality:p3 enhancement rust triage:needs-implementation
主要言語
Rust
スター
2
フォーク
0
平均マージ
2時間 55分
マージ済み PR(30日)
130

説明

Found in the 0.28.0 pre-release review (2026-09-08). Line references are as of main after #926.

`registry-evidence-client` and `registry-evidence-verifier` are the only two dependencies in `crates/registry-breg/Cargo.toml` (lines 227-228) without `optional = true`, so a `default = []` library build still links reqwest and tokio through the client. The always-compiled contract path imports their types: `action_evidence_contracts.rs` and `action_evidence_validation.rs` are ungated `pub mod` in `lib.rs`, and `compiler.rs:174` calls `compile_evidence` on every project compile.

Decision recorded in `products/breg/DECISIONS.md`: 0.28.0 ships the dependency unconditional; the gate is deferred to this ticket.

Proposed change:
- Make both dependencies optional behind an `evidence` feature that `runtime` enables.
- Gate the Evidence-typed contract compile behind the same feature, with a compile-time refusal (clear diagnostic) when a project declares evidence capabilities and the build lacks the feature.
- Collapse `action_evidence.rs`, `action_evidence_client.rs`, `action_evidence_config.rs`, `action_evidence_maintenance.rs` into one `action_evidence/` module tree so the feature has one gate.

Acceptance: `cargo check -p registry-breg` with default features links neither Evidence crate; `bregctl` and `breg` behave unchanged; a test proves the refusal diagnostic.

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

crates/registry-breg/Cargo.toml の 227-228 行と lib.rs から始め、次に compiler.rs:174 と名前が挙げられている action_evidence モジュールを調べます。まずデフォルト features で cargo check -p registry-breg を実行します。デフォルトビルドで両方の Evidence crate が除外され、runtime と bregctl/breg が変更されず、feature なしでの Evidence capabilities に対する拒否診断を検証するテストがあれば完了です。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
rust
領域
backend, build-system
issue の種類
機能追加
難易度
4/5
見積もり時間
3〜5日
活発さ
活発
明瞭さ
明確に書かれている
初心者へのやさしさ
48/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。