Skip to content

Commit 78fc626

Browse files
Merge branch 'main' into jonathan/fix-goose-builtin-config-compatible
2 parents 317a65a + b8fa1b5 commit 78fc626

File tree

16 files changed

+313
-6
lines changed

16 files changed

+313
-6
lines changed

.github/codex/home/config.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
model = "o3"
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
Attempt to solve the reported issue.
2+
3+
If a code change is required, create a new branch, commit the fix, and open a pull request that resolves the problem.
4+
5+
Here is the original GitHub issue that triggered this run:
6+
7+
### {CODEX_ACTION_ISSUE_TITLE}
8+
9+
{CODEX_ACTION_ISSUE_BODY}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
Review this PR and respond with a very concise final message, formatted in Markdown.
2+
3+
There should be a summary of the changes (1-2 sentences) and a few bullet points if necessary.
4+
5+
Then provide the **review** (1-2 sentences plus bullet points, friendly tone).
6+
7+
{CODEX_ACTION_GITHUB_EVENT_PATH} contains the JSON that triggered this GitHub workflow. It contains the `base` and `head` refs that define this PR. Both refs are available locally.
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
Troubleshoot whether the reported issue is valid.
2+
3+
Provide a concise and respectful comment summarizing the findings.
4+
5+
### {CODEX_ACTION_ISSUE_TITLE}
6+
7+
{CODEX_ACTION_ISSUE_BODY}

.github/workflows/codex.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Codex
2+
3+
on:
4+
issues:
5+
types: [opened, labeled]
6+
pull_request:
7+
branches: [main]
8+
types: [labeled]
9+
10+
jobs:
11+
codex:
12+
runs-on: ubuntu-latest
13+
permissions:
14+
contents: write
15+
issues: write
16+
pull-requests: write
17+
steps:
18+
# By default, Codex runs network disabled using --full-auto, so perform
19+
# any setup that requires network (such as installing dependencies)
20+
# before openai/codex-action.
21+
- name: Checkout repository
22+
uses: actions/checkout@v4
23+
24+
- name: Run Codex
25+
uses: openai/codex/.github/actions/codex@main
26+
with:
27+
openai_api_key: ${{ secrets.CODEX_OPENAI_API_KEY }}
28+
codex_args: --full-auto
29+
github_token: ${{ secrets.GITHUB_TOKEN }}
30+
codex_home: ./.github/codex/home

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
## [1.13.5](https://github.com/pathintegral-institute/mcpm.sh/compare/v1.13.4...v1.13.5) (2025-06-16)
2+
3+
4+
### Bug Fixes
5+
6+
* automated fix for [#171](https://github.com/pathintegral-institute/mcpm.sh/issues/171) via Codex ([#173](https://github.com/pathintegral-institute/mcpm.sh/issues/173)) ([88b554b](https://github.com/pathintegral-institute/mcpm.sh/commit/88b554b1d057a470cb44efc0cf26a98941291f35))
7+
18
## [1.13.4](https://github.com/pathintegral-institute/mcpm.sh/compare/v1.13.3...v1.13.4) (2025-06-07)
29

310

best_practices.md

Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
2+
<b>Pattern 1: When implementing command-line interfaces with Click, use consistent help option patterns and provide clear, structured help text with examples. Include both short (-h) and long (--help) options, and format examples using backslash-escaped blocks for proper display.
3+
</b>
4+
5+
Example code before:
6+
```
7+
@click.command()
8+
def my_command():
9+
"""Command description."""
10+
pass
11+
```
12+
13+
Example code after:
14+
```
15+
@click.command()
16+
@click.help_option("-h", "--help")
17+
def my_command():
18+
"""Command description.
19+
20+
Example:
21+
22+
\b
23+
mcpm command example
24+
"""
25+
pass
26+
```
27+
28+
<details><summary>Examples for relevant past discussions:</summary>
29+
30+
- https://github.com/pathintegral-institute/mcpm.sh/pull/46#discussion_r2038909708
31+
- https://github.com/pathintegral-institute/mcpm.sh/pull/119#discussion_r2059566646
32+
</details>
33+
34+
35+
___
36+
37+
<b>Pattern 2: When handling subprocess output streams, prefer reading from stderr for application logs and status information rather than stdout, as many applications follow the convention of writing logs to stderr while reserving stdout for data output.
38+
</b>
39+
40+
Example code before:
41+
```
42+
# Process both stdout and stderr
43+
if process.stdout:
44+
line = process.stdout.readline()
45+
if process.stderr:
46+
line = process.stderr.readline()
47+
```
48+
49+
Example code after:
50+
```
51+
# Focus on stderr for logs and status
52+
if process.stderr:
53+
line = process.stderr.readline()
54+
if line:
55+
console.print(line.rstrip())
56+
```
57+
58+
<details><summary>Examples for relevant past discussions:</summary>
59+
60+
- https://github.com/pathintegral-institute/mcpm.sh/pull/167#discussion_r2128177278
61+
</details>
62+
63+
64+
___
65+
66+
<b>Pattern 3: When implementing async handlers for web frameworks like Starlette, ensure handlers return proper Response objects and handle exceptions appropriately with try-catch blocks and proper cleanup in finally blocks.
67+
</b>
68+
69+
Example code before:
70+
```
71+
async def handle_request(request: Request) -> None:
72+
async with some_context() as context:
73+
await process_request(context)
74+
```
75+
76+
Example code after:
77+
```
78+
async def handle_request(request: Request) -> Response:
79+
try:
80+
async with some_context() as context:
81+
await process_request(context)
82+
except Exception as e:
83+
logger.error(f"Error: {e}", exc_info=True)
84+
finally:
85+
return Response()
86+
```
87+
88+
<details><summary>Examples for relevant past discussions:</summary>
89+
90+
- https://github.com/pathintegral-institute/mcpm.sh/pull/156#discussion_r2111437707
91+
</details>
92+
93+
94+
___
95+
96+
<b>Pattern 4: When managing server configurations and capabilities across multiple servers, implement proper conflict resolution strategies for duplicate names by either using strict mode to raise errors or auto-resolving conflicts with server-specific prefixes.
97+
</b>
98+
99+
Example code before:
100+
```
101+
# Direct assignment without conflict checking
102+
self.tools_mapping[tool.name] = tool
103+
```
104+
105+
Example code after:
106+
```
107+
tool_name = tool.name
108+
if tool_name in self.capabilities_to_server_id["tools"]:
109+
if self.strict:
110+
raise ValueError(f"Tool {tool_name} already exists")
111+
else:
112+
tool_name = f"{server_id}{SEPARATOR}{tool_name}"
113+
self.tools_mapping[tool_name] = tool
114+
self.capabilities_to_server_id["tools"][tool_name] = server_id
115+
```
116+
117+
<details><summary>Examples for relevant past discussions:</summary>
118+
119+
- https://github.com/pathintegral-institute/mcpm.sh/pull/76#discussion_r2050413886
120+
- https://github.com/pathintegral-institute/mcpm.sh/pull/76#discussion_r2050414500
121+
</details>
122+
123+
124+
___
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
{
2+
"display_name": "4EVERLAND Hosting MCP Server",
3+
"license": "MIT",
4+
"tags": [
5+
"4everland",
6+
"hosting",
7+
"cloud",
8+
"mcp"
9+
],
10+
"installations": {
11+
"4ever-mcpserver": {
12+
"type": "npm",
13+
"command": "npx",
14+
"args": [
15+
"-y",
16+
"@4everland/hosting-mcp@latest",
17+
"serve"
18+
],
19+
"description": "Run the 4EVERLAND MCP server directly with node",
20+
"env": {
21+
"TOKEN": "${4EVERLAND_HOSTING_AUTH_TOKEN}"
22+
}
23+
}
24+
},
25+
"arguments": {
26+
"TOKEN": {
27+
"description": "4everland Hosting auth key",
28+
"required": true,
29+
"example": "your_auth_key"
30+
}
31+
},
32+
"examples": [
33+
{
34+
"title": "deploy simple webapp",
35+
"description": "",
36+
"prompt": "generate a simple counter using html, then deploy it to 4ever and tell me how to view it"
37+
}
38+
],
39+
"name": "4everland-hosting-mcp",
40+
"repository": {
41+
"type": "git",
42+
"url": "https://github.com/4everland/4everland-hosting-mcp"
43+
},
44+
"homepage": "https://github.com/4everland/4everland-hosting-mcp#readme",
45+
"author": {
46+
"name": "4EVERLAND"
47+
},
48+
"description": "A Model Context Protocol (MCP) server implementation for 4EVERLAND Hosting enabling instant deployment of AI-generated code to decentralized storage networks like Greenfield, IPFS, and Arweave.",
49+
"categories": [
50+
"Dev Tools"
51+
],
52+
"is_official": true
53+
}

src/mcpm/clients/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,15 @@
88
from mcpm.clients.client_config import ClientConfigManager
99
from mcpm.clients.client_registry import ClientRegistry
1010
from mcpm.clients.managers.claude_desktop import ClaudeDesktopManager
11+
from mcpm.clients.managers.claude_code import ClaudeCodeManager
1112
from mcpm.clients.managers.cursor import CursorManager
1213
from mcpm.clients.managers.trae import TraeManager
1314
from mcpm.clients.managers.windsurf import WindsurfManager
1415

1516
__all__ = [
1617
"BaseClientManager",
1718
"ClaudeDesktopManager",
19+
"ClaudeCodeManager",
1820
"WindsurfManager",
1921
"CursorManager",
2022
"TraeManager",

src/mcpm/clients/base.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -418,7 +418,9 @@ def activate_profile(self, profile_name: str, router_config: Dict[str, Any], ali
418418
"""
419419
host = router_config["host"]
420420
port = router_config["port"]
421-
default_base_url = f"http://{host}:{port}/sse"
421+
422+
# Use streamable HTTP endpoint instead of the deprecated SSE one.
423+
default_base_url = f"http://{host}:{port}/mcp/"
422424

423425
server_config = self._format_router_server(profile_name, default_base_url, alias_name)
424426
return self.add_server(server_config)
@@ -688,7 +690,8 @@ def activate_profile(self, profile_name: str, router_config: Dict[str, Any], ali
688690
"""
689691
host = router_config["host"]
690692
port = router_config["port"]
691-
default_base_url = f"http://{host}:{port}/sse"
693+
# Use streamable HTTP endpoint.
694+
default_base_url = f"http://{host}:{port}/mcp/"
692695

693696
server_config = self._format_router_server(profile_name, default_base_url, alias_name)
694697
return self.add_server(server_config)

0 commit comments

Comments
 (0)