Skip to content

Commit 9b18e13

Browse files
committed
fix: don't constrain MCP server to single project
Removed --project flag from MCP server startup args. The flag sets BASIC_MEMORY_MCP_PROJECT env var which constrains ALL tool calls to that project, ignoring explicit project params from tools. Now relies on BM config's default_project for the default, while allowing cross-project access (cloud or local) via the project param.
1 parent c4dcf8e commit 9b18e13

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

bm-client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,7 @@ export class BmClient {
301301
private async connectFresh(): Promise<void> {
302302
const transport = new StdioClientTransport({
303303
command: this.bmPath,
304-
args: ["mcp", "--transport", "stdio", "--project", this.project],
304+
args: ["mcp", "--transport", "stdio"],
305305
cwd: this.cwd,
306306
env: this.env,
307307
stderr: "pipe",

tools/search.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,8 @@ export function registerSearchTool(
5454
},
5555
) {
5656
const limit = params.limit ?? 10
57-
log.debug(`bm_search: query="${params.query}" limit=${limit}`)
57+
log.debug(`bm_search: query="${params.query}" limit=${limit} project="${params.project ?? "default"}"`)
58+
5859

5960
const metadata =
6061
params.metadata_filters || params.tags || params.status

0 commit comments

Comments
 (0)