[BUG] aimdb-mcp: get_buffer_metrics cannot find a record by its key
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
まず tools/aimdb-mcp/src/tools/buffer_metrics.rs の41行目付近にあるフィルターを確認し、次に tools/aimdb-mcp/src/tools/profiling.rs の45行目付近にある対応するロジックと比較してください。キーがRust型名と異なるレコードのテストを追加するか、既存のテストを探してください。get_buffer_metrics がキーで検索したときにそのレコードを見つけ、テストが成功すれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Describe the bug
get_buffer_metrics takes a record_key, but it only matches that value against the record's Rust type name. When a record's key differs from its type name, querying by the real key returns found: false, even though the record exists.
The filter is in buffer_metrics.rs:41:
.filter(|r| r.name.contains(¶ms.record_key))
get_stage_profiling takes the same parameter and already matches both fields (profiling.rs:45).
To Reproduce
- Run an instance with a record whose key differs from its type name, for example key
motion.policywith typecontracts::Policy. - Call the MCP tool
get_buffer_metricswith{"record_key": "motion.policy"}. - The tool replies:
{
"found": false,
"message": "No records matching this key were found in the running instance.",
"record_key": "motion.policy"
}
Expected behavior
The tool finds the record by its key, as get_stage_profiling does. The fix is to match r.record_key as well as r.name, with a test where the two differ.
Environment
- OS: macOS 13 (Darwin 22.6)
- Rust Version: rustc 1.98.0
- AimDB Version: main at d9c7be0
Additional context
Seen against a host gateway over a Unix socket. The target instance may also be built without the metrics feature, but the lookup fails before that matters.
- 主要言語
- Rust
- スター
- 101
- フォーク
- 20
- 平均マージ
- 2時間 33分
- マージ済み PR(30日)
- 90
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
aimdb-dev/aimdb のほかの issue
-
🏷️ good first issue enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
メンテナーはふだん 1 日以内に返信
-
documentation
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
メンテナーはふだん 1 日以内に返信
-
enhancement
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
メンテナーはふだん 1 日以内に返信
-
dependencies
難易度 4/5 3〜5日 初心者へのやさしさ 44/100
メンテナーはふだん 1 日以内に返信
aimdb-dev/aimdb の issue をすべて見る
似ている issue
-
Panic on live viewport resize when unstyled elements exist in display: none subtree対応中かも @GoCoder7 が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
DioxusLabs/blitz#1488 ·
メンテナーはふだん 1 日以内に返信
-
S-Needs triage
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 77/100
vectordotdev/vrl#2042 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
メンテナーはふだん 1 日以内に返信