chore: PR4 — browser-mcp Phase B last-mile cleanup#361
Conversation
plan.md の PR4 (Phase B 完了 PR):
- packages/superset-browser-mcp に README.md を追加。アーキテクチャ図、
外部 CDP MCP との関係 (chrome-devtools-mcp / browser-use /
playwright-mcp に委譲する方針)、binding 解決フロー、dev 注意点を
まとめる。
- src/tools/index.ts の "endpoint itself ships in follow-up PRs"
コメントを削除。get_cdp_endpoint と get_connected_pane の役割を
明示的に書く。
- browser-mcp-bridge/server.ts から、PR2/3 で消した body-taking
endpoint 用に残っていた dead code を整理:
- `MAX_JSON_BODY_BYTES` / `PayloadTooLargeError` / `_readJson`
を削除 (現状すべてのエンドポイントが GET / POST 空ボディ)
- 413 ハンドリングも対応する catch 分岐を削除
- plan.md に Phase B Status を追記、PR1〜3 を shipped マーク、PR4 を
本 PR としてラベル付け。
📝 WalkthroughWalkthroughJSON リクエストボディサイズ制限ロジックとペイロードエラー処理を削除し、ブラウザ MCP ブリッジサーバーを簡素化。同時にパッケージドキュメント、ツール説明、ロードマップを更新して Phase B の完了を反映。 Changes
推定コード レビュー工数🎯 2 (Simple) | ⏱️ ~12分 関連する可能性のある PR
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@packages/superset-browser-mcp/README.md`:
- Around line 31-48: The fenced code block in the README architecture diagram
lacks a language tag which triggers markdownlint warnings; update the opening
fence from ``` to ```text (and keep the closing ```), e.g. change the block
starting with "Claude / Codex session" to begin with "```text" so the diagram is
explicitly marked as plain text and the lint warning is resolved.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: e5f5f35e-9662-4cf0-9b29-eb6cbdb59a50
📒 Files selected for processing (4)
apps/desktop/src/main/lib/browser-mcp-bridge/server.tspackages/superset-browser-mcp/README.mdpackages/superset-browser-mcp/src/tools/index.tsplan.md
💤 Files with no reviewable changes (1)
- apps/desktop/src/main/lib/browser-mcp-bridge/server.ts
| ``` | ||
| Claude / Codex session | ||
| │ (stdio tool call: get_cdp_endpoint) | ||
| ▼ | ||
| packages/superset-browser-mcp (this package) | ||
| │ HTTP over loopback, ~/.superset/browser-mcp.json | ||
| ▼ | ||
| apps/desktop main process | ||
| ├── session resolver (PPID → terminal pane → LLM session) | ||
| ├── binding store (sessionId ↔ paneId) | ||
| └── CDP filter proxy | ||
| │ ws(s)://…/cdp/<token>/devtools/page/<targetId> | ||
| ▼ | ||
| Chromium --remote-debugging-port (random port) | ||
| │ filter: only the bound pane's target is visible | ||
| ▼ | ||
| External CDP MCP (chrome-devtools-mcp / browser-use / …) | ||
| ``` |
There was a problem hiding this comment.
コードブロックに言語指定を追加してください
アーキテクチャ図のフェンスコードブロックに言語指定がありません。プレーンテキスト図の場合は ```text を使用することで、markdownlint の警告を解消できます。
📝 修正案
-```
+```text
Claude / Codex session
│ (stdio tool call: get_cdp_endpoint)
▼🧰 Tools
🪛 markdownlint-cli2 (0.22.0)
[warning] 31-31: Fenced code blocks should have a language specified
(MD040, fenced-code-language)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@packages/superset-browser-mcp/README.md` around lines 31 - 48, The fenced
code block in the README architecture diagram lacks a language tag which
triggers markdownlint warnings; update the opening fence from ``` to ```text
(and keep the closing ```), e.g. change the block starting with "Claude / Codex
session" to begin with "```text" so the diagram is explicitly marked as plain
text and the lint warning is resolved.
Summary
plan.md の PR4 (Phase B 完了 PR)。コードと文書を Phase B 後の最終形に揃える。
追加
クリーンアップ
Phase B 完了
これでプラン上の PR1〜PR4 すべて完了。今後 browser 自動化は外部 CDP MCP に依存し、本パッケージは binding ルーターとして最小に保つ。
Test plan
Summary by CodeRabbit
リリースノート
ドキュメンテーション
リファクター