feat(mcp): add a contributor-profile CLI command#6961
Conversation
|
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 #6961 +/- ##
===========================================
+ Coverage 82.38% 93.71% +11.32%
===========================================
Files 685 685
Lines 68379 68379
Branches 18730 18730
===========================================
+ Hits 56337 64080 +7743
+ Misses 9594 3302 -6292
+ Partials 2448 997 -1451
Flags with carried forward coverage won't be shown. Click here to find out more. |
|
Tip ✅ LoopOver review result - approve/merge recommendedReview updated: 2026-07-17 16:01:46 UTC
Review summary Nits — 5 non-blocking
Decision drivers
Context & advisory signals — never blocks the verdict
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
🧪 Chat with LoopOverAsk LoopOver 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://loopover.ai/docs/loopover-commands 🧪 Experimental — new and may change. 🟩 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 LoopOver, a quiet PR intelligence layer for OSS maintainers.
|
Closes #6737
Problem
The MCP tool
loopover_get_contributor_profile(src/mcp/server.ts:1992) mirrorsGET /v1/contributors/:login/profile(src/api/routes.ts:3093, gated byrequireContributorAccess— the same gatedecision-pack/repo-decisionalready satisfy). No CLI mirror existed, despite that family of contributor commands already sharing the identical route shape and login-resolution logic.Fix
Add a
contributor-profiletop-level CLI command, mirroringdecisionPackCli's structure: it resolves the login from--login→ the active session →LOOPOVER_LOGIN→GITHUB_LOGIN(identical to the sibling commands, so a logged-in contributor never retypes their own login), GETs/v1/contributors/{login}/profile, prints a one-line summary on the plain path and the full payload with--json. Namedcontributor-profilebecause the top-levelprofilecommand is already taken (it manages MCP client profiles). Registered in the command-completion map so the shell completers list it.Tests
New
test/unit/mcp-cli-contributor-profile.test.ts:--loginmirrorsGET /v1/contributors/:login/profileand prints the summary (plain) / full payload (--json) — asserting output parity between the two surfaces;--loginresolves fromLOOPOVER_LOGINand url-encodes it into the path;Pass --loginguidance and issues no request.A
/v1/contributors/:login/profilefixture route is added to the shared CLI harness (additive, mirroring the existing contributor-route fixtures).Validation
npx vitest run test/unit/mcp-cli-contributor-profile.test.ts→ 3/3 pass;test/unit/mcp-cli-basics.test.ts(the completer) still green.npm run typecheck→ clean (0 errors);node --checkpasses.packages/loopover-mcp/**andtest/**are outside the Codecovinclude, so nocodecov/patchobligation.