Skip to content

feat(mcp-cli): register gittensory_get_burden_forecast stdio proxy tool - #4322

Closed
reyanthony062001-ops wants to merge 1 commit into
JSONbored:mainfrom
reyanthony062001-ops:feat/mcp-cli-burden-forecast-stdio
Closed

feat(mcp-cli): register gittensory_get_burden_forecast stdio proxy tool#4322
reyanthony062001-ops wants to merge 1 commit into
JSONbored:mainfrom
reyanthony062001-ops:feat/mcp-cli-burden-forecast-stdio

Conversation

@reyanthony062001-ops

Copy link
Copy Markdown
Contributor

What

The hosted MCP server registers gittensory_get_burden_forecast (src/mcp/server.ts), but the stdio package (packages/gittensory-mcp/bin/gittensory-mcp.js) never registered it, so a maintainer running the local stdio server could not pull the cached burden forecast (projected review load, queue-growth risk, stale-PR signals). The maintainer-triage agent profile in the stdio bin already lists the tool under recommendedTools, so registering it also reconciles that dangling reference.

There is no dedicated GET route for the forecast: the API serves it as the burdenForecast / burdenForecastFreshness slice of GET /v1/repos/:owner/:repo/intelligence (buildRepoIntelligenceResponse in src/api/routes.ts). The new stdio tool therefore proxies that endpoint via apiGet with the standard ownerRepo input handling, returns the forecast slice with its freshness marker, and mirrors the hosted tool's not_found contract when no forecast is cached.

The tool is wired through STDIO_TOOL_DESCRIPTORS (#2233) so registration and the gittensory-mcp tools inventory stay in sync.

Note: this change previously ran as PR #4229, where the review gate approved it ("safe to merge") twice; that PR was closed when its final rebase landed during the src/queue/processors.ts duplicate-implementation breakage on main (fixed by #4318). This is the fresh resubmission on top of the fixed main, per the closure guidance.

Deliverables

  • Register gittensory_get_burden_forecast in packages/gittensory-mcp/bin/gittensory-mcp.js proxying the burden-forecast data via apiGet (served on the repo intelligence endpoint - no dedicated burden-forecast GET route exists).
  • ownerRepo input handling matching existing repo-scoped tools (gittensory_get_repo_context).
  • Subprocess stdio test for listing + payload, plus the not_found branch, against dedicated acme/* fixture repos so the shared owner/repo intelligence fixture stays free for sibling tools.

Validation

Closes #2230

The hosted MCP server registers gittensory_get_burden_forecast
(src/mcp/server.ts), but the stdio package never did, so a maintainer
running the local stdio server cannot pull the cached burden forecast
(projected review load, queue-growth risk, stale-PR signals). The
maintainer-triage agent profile in the stdio bin already lists the tool
under recommendedTools, so registering it also reconciles that dangling
reference.

There is no dedicated GET route for the forecast: the API serves it as
the burdenForecast / burdenForecastFreshness slice of
/v1/repos/:owner/:repo/intelligence (buildRepoIntelligenceResponse in
src/api/routes.ts). The new stdio tool therefore proxies that endpoint
via apiGet with the standard ownerRepo input handling, returns the
forecast slice with its freshness marker, and mirrors the hosted tool's
not_found contract when no forecast is cached.

The tool is wired through STDIO_TOOL_DESCRIPTORS so registration and
the tools inventory stay in sync, and covered by a subprocess stdio
test (tool listing, proxied payload, and the not_found branch) against
dedicated fixture repos so the shared owner/repo intelligence fixture
stays free for sibling tools.

Closes JSONbored#2230
@superagent-security

Copy link
Copy Markdown
Contributor

Superagent didn't find any vulnerabilities or security issues in this PR.

@loopover-orb loopover-orb Bot added the gittensor:feature Gittensor-scored feature linked to a feature issue — scores a 0.25x multiplier. label Jul 8, 2026
@loopover-orb

loopover-orb Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

Caution

🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥

🛑 Gittensory review result - reject/close recommended

Review updated: 2026-07-08 20:57:19 UTC

3 files · 1 AI reviewer · 1 blocker · readiness 100/100 · CI green · clean

🛑 Suggested Action - Reject/Close

  • Linked issue overlaps another open PR — Review the related PRs before spending reviewer time on duplicate work.

Review summary
This is a clean, narrowly-scoped stdio proxy addition: it registers gittensory_get_burden_forecast in packages/gittensory-mcp/bin/gittensory-mcp.js, mirroring the existing ownerRepo-based tool pattern and the hosted tool's not_found contract by proxying GET /v1/repos/:owner/:repo/intelligence and slicing out burdenForecast/burdenForecastFreshness. It reconciles the dangling recommendedTools reference in the maintainer-triage profile and closes out the issue-scope requirement per the PR description's link to #2233/#2230 and the prior #4229 closure history. Tests exercise both the found and not_found branches against dedicated acme/widgets and acme/quiet fixtures, keeping the shared owner/repo fixture free for other tools, and CI is green across build/typecheck/tests.

Nits — 5 non-blocking
  • packages/gittensory-mcp/bin/gittensory-mcp.js: the inline comment restating 'no dedicated GET route' duplicates what's already in the PR description — fine to trim if you want the file leaner, but not required.
  • The stdio bin file is already flagged as long (~568 lines, threshold 400) by repo tooling; this PR only adds 28 lines to it, but if you're touching this file again soon it may be worth splitting tool registrations into a separate module.
  • test/unit/mcp-cli-burden-forecast.test.ts: consider also asserting the tool's description text matches the STDIO_TOOL_DESCRIPTORS entry, to catch future drift between the descriptor list and stdioToolDescription() lookups in one test rather than relying on the tools-inventory test elsewhere.
  • If there's ever a dedicated burden-forecast GET route added later, this proxy and its test fixtures should be updated to hit it directly instead of piggybacking on /intelligence.
  • Consider a follow-up test verifying gittensory-mcp tools inventory output includes this tool's description verbatim, since the PR description calls out keeping STDIO_TOOL_DESCRIPTORS and the inventory in sync.

Why this is blocked

  • Linked issue overlaps another open PR — Review the related PRs before spending reviewer time on duplicate work.
Signal Result Evidence
Code review ❌ 1 blocker 1 reviewer
Linked issue ✅ Linked #2230
Related work ✅ No active overlap found No same-issue or scoped active PR overlap found.
Change scope ✅ 20/20 Low review scope from cached public metadata (1 linked issue).
Validation posture ✅ 25/25 PR body includes validation/test evidence.
Contributor workload ✅ 10/10 Author activity: 0 registered-repo PR(s), 0 merged, 0 issue(s).
Contributor context ❌ No public Gittensor match reyanthony062001-ops; not a blocker.
Gate result ❌ Blocking Repo-configured hard blocker found.
Review context
  • Author: reyanthony062001-ops
  • Role context: outside_contributor
  • Public audience mode: oss maintainer
  • Lane context: Repository is configured for direct PR review.
  • Public profile languages: not available
  • Contributor context: Public profile only; not a blocker.
  • PR-specific overlap: none found.
Contributor next steps
  • Keep the PR focused and include validation evidence before maintainer review.
Signal definitions
  • Related work = same linked issue, overlapping active PRs, or title/path similarity.
  • Change scope = cached public metadata such as size labels, draft state, and review-burden hints.
  • Validation posture = whether the PR provides enough public validation/test evidence for maintainer review.
  • Contributor workload = public contributor activity and cleanup pressure, not a repo-wide quality failure.
  • Contributor context = public GitHub/Gittensor identity context; non-Gittensor status is not a blocker.

🟩 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.

  • Re-run Gittensory review

@codecov

codecov Bot commented Jul 8, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.94%. Comparing base (d329591) to head (fe30c14).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4322   +/-   ##
=======================================
  Coverage   93.94%   93.94%           
=======================================
  Files         397      397           
  Lines       36736    36736           
  Branches    13428    13428           
=======================================
  Hits        34511    34511           
  Misses       1569     1569           
  Partials      656      656           
🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@loopover-orb

loopover-orb Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

Gittensory is closing this pull request on the maintainer's behalf (Linked issue overlaps another open PR; duplicate of another open PR). This is an automated maintenance action — to pursue this change, please open a new pull request with the issues resolved. Closed PRs may be analyzed later to improve review accuracy, but they are not automatically reopened or re-reviewed.

@loopover-orb loopover-orb Bot closed this Jul 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gittensor:feature Gittensor-scored feature linked to a feature issue — scores a 0.25x multiplier.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(mcp-cli): add stdio tool gittensory_get_burden_forecast (proxy the hosted tool)

1 participant