File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -54,6 +54,11 @@ func main() {
5454 // Create client with the transport
5555 c = client .NewClient (stdioTransport )
5656
57+ // Start the client
58+ if err := c .Start (ctx ); err != nil {
59+ log .Fatalf ("Failed to start client: %v" , err )
60+ }
61+
5762 // Set up logging for stderr if available
5863 if stderr , ok := client .GetStderr (c ); ok {
5964 go func () {
@@ -84,11 +89,6 @@ func main() {
8489 c = client .NewClient (httpTransport )
8590 }
8691
87- // Start the client
88- if err := c .Start (ctx ); err != nil {
89- log .Fatalf ("Failed to start client: %v" , err )
90- }
91-
9292 // Set up notification handler
9393 c .OnNotification (func (notification mcp.JSONRPCNotification ) {
9494 fmt .Printf ("Received notification: %s\n " , notification .Method )
You can’t perform that action at this time.
0 commit comments