cline icon indicating copy to clipboard operation
cline copied to clipboard

Can't connect the MCP server BraveSearch

Open bodzebod opened this issue 1 year ago • 5 comments

What happened?

Hi, I tried to install the MCP server BraveSearch. While the server seems to start flawlessly using npx, Cline can't connect it and raises an error:

Error executing MCP tool: Not connected

Then Cline continues to suggest other options, and even built a docker image and started a docker container. The container starts well, but Cline keeps on raising the same error. Note that I could provide it with my bravesearch API key successfully, it doesn't raise any error with that.

I use Clause 3.5 sonnet model.

Steps to reproduce

  1. Install BraveSearch MCP server with Claude 3.5 sonnet
  2. Fill your API key
  3. Cline raises the error "Error executing MCP tool: Not connected"

Relevant API REQUEST output


Operating System

windows 11

Cline Version

3.4.5

Additional context

Image

Image

bodzebod avatar Feb 21 '25 09:02 bodzebod

I've let Cline continue, it gave up with the container and retried working with npx. It did some changes somewhere:

Image

I had to start manually the MCP server as Cline didn't make it by itself:

$env:BRAVE_API_KEY="MY_API_KEY"; npx -y @modelcontextprotocol/server-brave-search

Then, it could connect it successfully! I don't know what changed, but it's working finally.

bodzebod avatar Feb 21 '25 09:02 bodzebod

In my previous comment, it worked when I started manually the MCP server. Now, I understand it should start automatically, which is not the case. I tried to deploy another MCP server (server-github) and run into the same problem again.

In addition, I rebooted and Cline can no longer connect the Brave Search MCP server again...

bodzebod avatar Feb 21 '25 11:02 bodzebod

you can check your mcp_settings file, you have to write "cmd" in command term, and add "/c","npx" to your "args" term,just like the following example: "sequential-thinking": { "command": "cmd", "args": [ "/c", "npx", "-y", "@modelcontextprotocol/server-sequential-thinking" ], "autoApprove": [ "sequentialthinking" ] }

cpyer11 avatar Mar 15 '25 10:03 cpyer11

looks like it did the trick, many thanks!

bodzebod avatar Mar 17 '25 08:03 bodzebod

Unfortunately it did not fixed issue for me. I still get Not Connected for every MCP while when I use Claude app MCP works.

Mistic92 avatar Apr 15 '25 11:04 Mistic92