Skip to content

chore(mcp): add tsc pipeline and convert Phase 1+2 libs to TypeScript - #7397

Closed
RealDiligent wants to merge 4 commits into
JSONbored:mainfrom
RealDiligent:feat/mcp-ts-phase1-2-7329-v2
Closed

chore(mcp): add tsc pipeline and convert Phase 1+2 libs to TypeScript#7397
RealDiligent wants to merge 4 commits into
JSONbored:mainfrom
RealDiligent:feat/mcp-ts-phase1-2-7329-v2

Conversation

@RealDiligent

Copy link
Copy Markdown
Contributor

Summary

Closes #7329

Phase 1 deliverables from #7328 are included as the required build-pipeline prerequisite for Phase 2. bin/loopover-mcp.js is untouched (Phase 3).

Supersedes #7396 (closed for CI npm ci lockfile sync / trailing whitespace; both fixed here).

Test plan

  • npm --workspace @loopover/mcp run build
  • npm ci succeeds with updated lockfile
  • unit: mcp-cli-error, mcp-package-skeleton, format-table, redact-local-path, mcp-local-telemetry, local-branch
  • CI: validate-code, validate-tests-merge, codecov/patch

Made with Cursor

RealDiligent and others added 3 commits July 20, 2026 12:24
Prove the @loopover/mcp build pipeline (mirroring miner Phase 1) and convert the four small utilities plus local-branch so Phase 2 (JSONbored#7329) can land with Closes linkage.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
@RealDiligent
RealDiligent requested a review from JSONbored as a code owner July 20, 2026 04:37
@superagent-security

Copy link
Copy Markdown
Contributor

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

Co-authored-by: Cursor <cursoragent@cursor.com>
@codecov

codecov Bot commented Jul 20, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 66.86047% with 114 lines in your changes missing coverage. Please review.
✅ Project coverage is 92.13%. Comparing base (32e0998) to head (edfd581).

Files with missing lines Patch % Lines
packages/loopover-mcp/lib/local-branch.ts 61.92% 56 Missing and 51 partials ⚠️
packages/loopover-mcp/lib/format-table.ts 74.07% 0 Missing and 7 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7397      +/-   ##
==========================================
+ Coverage   91.19%   92.13%   +0.94%     
==========================================
  Files         716      633      -83     
  Lines       72733    52099   -20634     
  Branches    20578    17063    -3515     
==========================================
- Hits        66326    48001   -18325     
+ Misses       5365     3176    -2189     
+ Partials     1042      922     -120     
Flag Coverage Δ
rees ?
shard-1 26.35% <32.26%> (-9.55%) ⬇️
shard-2 39.56% <36.62%> (-1.90%) ⬇️
shard-3 35.94% <3.77%> (-2.99%) ⬇️
shard-4 41.64% <6.68%> (+1.76%) ⬆️
shard-5 38.47% <5.81%> (+11.27%) ⬆️
shard-6 31.55% <0.00%> (+0.24%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
packages/loopover-mcp/lib/cli-error.ts 100.00% <100.00%> (ø)
packages/loopover-mcp/lib/redact-local-path.ts 100.00% <100.00%> (ø)
packages/loopover-mcp/lib/telemetry.ts 100.00% <100.00%> (ø)
packages/loopover-mcp/lib/format-table.ts 74.07% <74.07%> (ø)
packages/loopover-mcp/lib/local-branch.ts 61.92% <61.92%> (ø)

... and 85 files with indirect coverage changes

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

loopover-orb Bot commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Caution

🛑 LoopOver review result - reject/close recommended

Review updated: 2026-07-20 04:50:23 UTC

29 files · 1 AI reviewer · 1 blocker · CI failing · unstable

🛑 Suggested Action - Reject/Close

Review summary
The AI review returned blocking findings for this change but did not include a separate narrative summary. Review the blockers below before deciding this PR.

Blockers

  • codecov/patch is failing at 66.86% vs. the required 99% target, meaning a substantial fraction of the newly added/converted TypeScript lines (particularly in packages/loopover-mcp/lib/local-branch.ts) lack test coverage — this needs to be closed before merge per this repo's patch-coverage bar.
Nits — 3 non-blocking
  • classifyScorerExecFailure in local-branch.ts (~local-branch.js:458) has grown to roughly cyclomatic complexity 16 across many stdout/stderr/exitCode branches; consider extracting the JSON-sniffing branches into a small helper for readability.
  • format-table.ts's JSDoc-style header comment duplicates the one already on the compiled .js output; verify the `.d.ts` allowlist change in scripts/mcp-package-allowlist.mjs is exercised by the added mcp-package-skeleton test rather than just asserted structurally.
  • Add or extend unit tests in test/unit/local-branch.test.ts for the branches in classifyScorerExecFailure (timeout, non-zero exit, malformed JSON via stdout vs stderr) since that function carries the highest complexity and the coverage numbers suggest it's under-exercised.

Why this is blocked

  • codecov/patch is failing at 66.86% vs. the required 99% target, meaning a substantial fraction of the newly added/converted TypeScript lines (particularly in packages/loopover-mcp/lib/local-branch.ts) lack test coverage — this needs to be closed before merge per this repo's patch-coverage bar.
📋 Copy for AI agents — paste into your coding agent
Fix the following blocker(s) from this PR review:

1. codecov/patch is failing at 66.86% vs. the required 99% target, meaning a substantial fraction of the newly added/converted TypeScript lines \(particularly in packages/loopover-mcp/lib/local-branch.ts\) lack test coverage — this needs to be closed before merge per this repo's patch-coverage bar.

CI checks failing

  • codecov/patch — 66.86% of diff hit (target 99.00%)

Decision drivers

  • ❌ Code review — 1 blocker (1 reviewer)
  • ❌ Gate result — Blocking (Repo-configured hard blocker found.)
Context & advisory signals — never blocks the verdict
Signal Result Evidence
Linked issue ✅ Linked #7329
Related work ⚠️ 3 scoped overlaps Top overlaps are listed below; lower-confidence bulk is hidden.
Change scope ❌ 8/20 High 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: 398 registered-repo PR(s), 190 merged, 33 issue(s).
Contributor context ✅ Confirmed Gittensor contributor RealDiligent; Gittensor profile; 398 PR(s), 33 issue(s).
Improvement ✅ Minor risk: clean · value: minor · LLM: moderate
Linked issue satisfaction

Addressed
The PR adds packages/loopover-mcp/lib/local-branch.ts as the real TypeScript source (with the corresponding compiled .js/.d.ts artifacts), fulfilling the issue's core ask of converting local-branch.js to TypeScript on top of the Phase 1 tsc build pipeline, with no behavior change intended and existing tests retained.

Review context
  • Author: RealDiligent
  • Role context: outside_contributor
  • Public audience mode: oss maintainer
  • Lane context: Repository is configured for direct PR review.
  • Public profile languages: Python, JavaScript, Ruby, Svelte, TypeScript, Markdown, MDX
  • Official Gittensor activity: 398 PR(s), 33 issue(s).
  • Related work: Titles/paths share 7 meaningful terms. (issue #7328)
  • Related work: Titles/paths share 5 meaningful terms. (issue #7330)
  • Related work: Titles/paths share 11 meaningful terms. (issue #7329, issue #7328)
  • Additional title-only matches omitted; title-only overlap does not block.
Contributor next steps
  • Start here: Review top overlaps.
  • Then work through the remaining 2 steps in the Signals table above.
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.
🧪 Chat with LoopOver

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

  • @loopover ask &lt;question&gt; answers contribution-quality Q&A with source citations and freshness.
  • @loopover chat &lt;question&gt; answers in natural prose from cached decision-pack facts via local inference (maintainer/collaborator; read-only).
  • A plain-language @loopover mention with a real question is routed to the closest matching read-only command automatically — no exact syntax required.

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.

  • Re-run LoopOver review

@loopover-orb

loopover-orb Bot commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

LoopOver is closing this pull request on the maintainer's behalf (CI is failing (codecov/patch); AI reviewers agree on a likely critical defect: codecov/patch is failing at 66.86% vs. the required 99% target, meaning a substantial fraction of the newly added/converted TypeScript lines (particularly in packages/loopover-mcp/lib/local-branch.ts) lack test coverage — this needs to be closed before merge per this repo's patch-coverage bar.). 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.

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.

chore(mcp): convert lib/local-branch.js to TypeScript (Phase 2 of #7291)

1 participant