feat(miner): expose the portfolio-queue dashboard as a read-only MCP tool#5298
Conversation
…tool Add gittensory_miner_get_portfolio_dashboard to the gittensory-miner MCP server (scaffold JSONbored#5153): a read-only wrapper over the existing collectPortfolioDashboard aggregator, returning per-repo backlog status counts, totals, and the oldest-queued age -- the same data 'gittensory-miner queue dashboard --json' prints locally. Opens the portfolio-queue store only when invoked and closes any store it opened; store opener + clock are injectable for tests. No new aggregation logic, no new files or dependencies. Closes JSONbored#5155
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #5298 +/- ##
=======================================
Coverage 94.37% 94.37%
=======================================
Files 474 474
Lines 40114 40114
Branches 14627 14627
=======================================
Hits 37856 37856
Misses 1583 1583
Partials 675 675
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
|
Tip 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 ✅ Gittensory review result - approve/merge recommendedReview updated: 2026-07-12 13:22:05 UTC
✅ Suggested Action - Approve/Merge
Review summary Nits — 5 non-blocking
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
[BETA] Chat with GittensoryAsk Gittensory a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://gittensory.aethereal.dev/docs/gittensory-commands 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.
|
Adds
gittensory_miner_get_portfolio_dashboardto the gittensory-miner MCP server (scaffold #5153, merged in #5254) — remote/agent-facing, read-only introspection into per-repo backlog health.What this adds
collectPortfolioDashboard()aggregator (packages/gittensory-miner/lib/portfolio-dashboard.js) — no new aggregation logic. Returns exactly what the aggregator already produces: per-repo status counts (queued / in_progress / done), totals, and the oldest-queued age in ms — the same datagittensory-miner queue dashboard --jsonprints locally.MinerMcpServerOptions) so tests drive it without on-disk AMS state — mirroringrunPortfolioDashboard's own seam.bin/gittensory-miner-mcp.js+ its.d.ts) and documents the tool in the README.Validation (local)
tsc --noEmit: 0 errors.viteston the three affected files (miner-mcp-scaffold,miner-package-skeleton,check-miner-package): 19/19 pass — including new cases for a multi-repo backlog (status counts / totals / oldest-queued age), the empty-queue edge, and an invariant asserting the tool output is structurally identical tocollectPortfolioDashboard()(the wrapper adds no drift).node scripts/check-miner-package.mjs,docs:drift-check,git diff --check: all clean.Note:
packages/gittensory-miner/**sits outside vitest'scoverage.include, socodecov/patchcannot measure it yet (closed separately by #4864/#4865); the tests above enforce full behavioral coverage regardless.Closes #5155