on main help sign in
Merge remote-tracking branch 'origin/main' into fix-openai-provider
commitcea9e80e34dafa8f6f2bedc44a7574d2e14454b6 authorKujtim Hoxha <kujtimii.h@gmail.com> dateMon 4 Aug 2025, 17:44 (1 year ago) parent1b50cb687ee7df
7 files changed+57−8
.github/cla-signatures.json+40 .github/labeler.yml+4 .github/workflows/cla.yml+1−1 .github/workflows/issue-labeler.yml+1−1 go.mod+1−1 go.sum+2−2 internal/llm/agent/mcp-tools.go+8−3
.github/cla-signatures.json+40
@@ -183,6 +183,46 @@
183183 "created_at": "2025-08-01T22:18:28Z",
184184 "repoId": 987670088,
185185 "pullRequestNo": 480
186+ },
187+ {
188+ "name": "yumosx",
189+ "id": 141902143,
190+ "comment_id": 3146472558,
191+ "created_at": "2025-08-02T12:24:29Z",
192+ "repoId": 987670088,
193+ "pullRequestNo": 504
194+ },
195+ {
196+ "name": "bold84",
197+ "id": 21118257,
198+ "comment_id": 3146962342,
199+ "created_at": "2025-08-03T04:07:16Z",
200+ "repoId": 987670088,
201+ "pullRequestNo": 519
202+ },
203+ {
204+ "name": "jooray",
205+ "id": 1028688,
206+ "comment_id": 3148713433,
207+ "created_at": "2025-08-03T21:35:15Z",
208+ "repoId": 987670088,
209+ "pullRequestNo": 527
210+ },
211+ {
212+ "name": "Ed4ward",
213+ "id": 153800328,
214+ "comment_id": 3150375016,
215+ "created_at": "2025-08-04T12:16:16Z",
216+ "repoId": 987670088,
217+ "pullRequestNo": 539
218+ },
219+ {
220+ "name": "ngnhng",
221+ "id": 51743767,
222+ "comment_id": 3150846779,
223+ "created_at": "2025-08-04T14:01:30Z",
224+ "repoId": 987670088,
225+ "pullRequestNo": 546
186226 }
187227 ]
188228}
.github/labeler.yml+4
@@ -1,3 +1,5 @@
1+"area: ci":
2+ - "/^ci: /i"
13"area: diff":
24 - "/diff/i"
35"area: images":
@@ -40,3 +42,5 @@
4042 - "/(openai|gpt)/i"
4143"provider: openrouter":
4244 - "/openrouter/i"
45+"provider: qwen":
46+ - "/qwen/i"
.github/workflows/cla.yml+1−1
@@ -29,7 +29,7 @@ jobs:
2929 path-to-signatures: ".github/cla-signatures.json"
3030 path-to-document: "https://github.com/charmbracelet/crush/blob/main/CLA.md"
3131 branch: "main"
32− allowlist: dependabot[bot]
32+ allowlist: charmcli,charmcrush,dependabot[bot]
3333 custom-pr-sign-comment: "I have read the Contributor License Agreement (CLA) and hereby sign the CLA."
3434 custom-notsigned-precomment: "Thank you for your submission. We really appreciate it! Like many open-source projects, we ask that you sign our [Contributor License Agreement](https://github.com/charmbracelet/crush/blob/main/CLA.md) before we can accept your contribution. You can sign the CLA by just posting a Pull Request comment same as the below format."
3535 lock-pullrequest-aftermerge: false
.github/workflows/issue-labeler.yml+1−1
@@ -3,7 +3,7 @@ name: Issue Labeler
33on:
44 issues:
55 types: [opened]
6− pull_request:
6+ pull_request_target:
77 types: [opened]
88 workflow_dispatch:
99 inputs:
go.mod+1−1
@@ -27,7 +27,7 @@ require (
2727 github.com/google/uuid v1.6.0
2828 github.com/invopop/jsonschema v0.13.0
2929 github.com/joho/godotenv v1.5.1
30− github.com/mark3labs/mcp-go v0.34.0
30+ github.com/mark3labs/mcp-go v0.36.0
3131 github.com/muesli/termenv v0.16.0
3232 github.com/ncruces/go-sqlite3 v0.25.0
3333 github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646
go.sum+2−2
@@ -180,8 +180,8 @@ github.com/lucasb-eyer/go-colorful v1.2.0 h1:1nnpGOrhyZZuNyfu1QjKiUICQ74+3FNCN69
180180github.com/lucasb-eyer/go-colorful v1.2.0/go.mod h1:R4dSotOR9KMtayYi1e77YzuveK+i7ruzyGqttikkLy0=
181181github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0=
182182github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc=
183−github.com/mark3labs/mcp-go v0.34.0 h1:eWy7WBGvhk6EyAAyVzivTCprE52iXJwNtvHV6Cv3bR0=
184−github.com/mark3labs/mcp-go v0.34.0/go.mod h1:rXqOudj/djTORU/ThxYx8fqEVj/5pvTuuebQ2RC7uk4=
183+github.com/mark3labs/mcp-go v0.36.0 h1:rIZaijrRYPeSbJG8/qNDe0hWlGrCJ7FWHNMz2SQpTis=
184+github.com/mark3labs/mcp-go v0.36.0/go.mod h1:T7tUa2jO6MavG+3P25Oy/jR7iCeJPHImCZHRymCn39g=
185185github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY=
186186github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y=
187187github.com/mattn/go-runewidth v0.0.16 h1:E5ScNMtiwvlvB5paMFdw9p4kSQzbXFikJ5SQO6TULQc=
internal/llm/agent/mcp-tools.go+8−3
@@ -11,10 +11,8 @@ import (
1111 "github.com/charmbracelet/crush/internal/config"
1212 "github.com/charmbracelet/crush/internal/csync"
1313 "github.com/charmbracelet/crush/internal/llm/tools"
14− "github.com/charmbracelet/crush/internal/version"
15−
1614 "github.com/charmbracelet/crush/internal/permission"
17−
15+ "github.com/charmbracelet/crush/internal/version"
1816 "github.com/mark3labs/mcp-go/client"
1917 "github.com/mark3labs/mcp-go/client/transport"
2018 "github.com/mark3labs/mcp-go/mcp"
@@ -191,6 +189,7 @@ func createMcpClient(m config.MCPConfig) (*client.Client, error) {
191189 return client.NewStreamableHttpClient(
192190 m.URL,
193191 transport.WithHTTPHeaders(m.ResolvedHeaders()),
192+ transport.WithLogger(mcpHTTPLogger{}),
194193 )
195194 case config.MCPSse:
196195 return client.NewSSEMCPClient(
@@ -201,3 +200,9 @@ func createMcpClient(m config.MCPConfig) (*client.Client, error) {
201200 return nil, fmt.Errorf("unsupported mcp type: %s", m.Type)
202201 }
203202}
203+
204+// for MCP's HTTP client.
205+type mcpHTTPLogger struct{}
206+
207+func (l mcpHTTPLogger) Errorf(format string, v ...any) { slog.Error(fmt.Sprintf(format, v...)) }
208+func (l mcpHTTPLogger) Infof(format string, v ...any) { slog.Info(fmt.Sprintf(format, v...)) }