feat(mcp): prefer Local HTTP over opening SQLite - #554
Conversation
Map MCP tools onto the desktop loopback API when DRIPNEX_LOCAL_SERVER_URL and DRIPNEX_LOCAL_TOKEN are set. Keep the SQLite path as fallback. Add status, notebook CRUD, tag writes, and changes tools. Writes stay gated by mcp.json / DRIPNEX_MCP_WRITES.
|
Warning Review limit reached
Next review available in: 8 minutes Limit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?Wait for the limit to reset, then comment An organization admin can change what happens after included review limits in Billing. How do review limits work?CodeRabbit enforces per-developer PR review limits within each organization. For paid Pro and Pro+ reviews, CodeRabbit uses a developer's included PR review attempts over the past 7 days to set the current hourly allowance. At typical activity levels, the full plan allowance applies. Higher sustained activity can lower the allowance until earlier attempts leave the 7-day window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (15)
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 |
Lock note/book/tag/changes calls to the Local HTTP shapes and keep prepareFtsQuery private to the SQLite store.
Settings → Integrations → MCP now pastes DRIPNEX_LOCAL_SERVER_URL and DRIPNEX_LOCAL_TOKEN when the loopback API is on. DRIPNEX_DB_PATH stays the fallback only when HTTP is off. Writes remain the separate toggle.
CodeQL flagged `rawUrl.replace(/\/+$/, '')` as js/polynomial-redos (high). `/+$` backtracks quadratically on a long run of slashes that is not at the end of the string: 40k slashes took ~1.3s. Replace it with a linear scan. Adds a test with a 100ms budget on that pathological input, plus one covering multiple trailing slashes. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
Pushed a fix for the CodeQL
mcp-server tests: 42/42 green. |
github-code-quality flagged `data !== null` as a comparison between inconvertible types. The preceding `data &&` already excludes null and undefined, so the check was dead. Behaviour is unchanged; the 401 case in httpClient.test.ts covers this branch. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
|
🎉 This PR is included in version 0.17.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Summary
Wire
@dripnex/mcp-serverto Dripnex Local HTTP so Cursor / Grok / Claude talk Bearer loopback instead of opening SQLite when the HTTP env is set. Settings → Integrations → MCP now copies that same HTTP env.DRIPNEX_LOCAL_SERVER_URL+DRIPNEX_LOCAL_TOKEN(loopback only). SQLite (DRIPNEX_DB_PATH) remains the fallback when those are unset.localServer.ts(notes, search, books=notebooks, tags).dripnex_status, notebook CRUD, tag create/update,dripnex_get_changes.DELETE /api/notes/:idis trash;?permanent=1is hard delete (dripnex_trash_notepermanent).mcp.json) /DRIPNEX_MCP_WRITES. Enabling Local HTTP is not a write grant (verified:httpApiEnabledvsmcpWritesare separate). Flipping Allow writes does not change the copied snippet.DRIPNEX_LOCAL_SERVER_URL+DRIPNEX_LOCAL_TOKEN(the URL and token already shown in the panel) when Local HTTP or MCP is on.DRIPNEX_DB_PATHis only used when HTTP is off. The launch path stays the realmcp-serverentry when the app knows it; otherwise/ABS/PATH/...remains a placeholder — HTTP env is still preferred.fetch. HTTP store mapping is covered with a stub client. Snippet tests useplaceholder-tokenand/tmppaths only.docs/ai/is not ondevelop— it lives ondocs/ai-mcp-plan. Env and Cursor/Grok config are inpackages/mcp-server/README.md(placeholders only; no tokens).Type of Change
Checklist
developbranch (notmain)typecheckpassed on pushfts5-triggersfails in this cloud Node build (no such module: fts5) — pre-existing, file not changed