ruby-mcp-client 0.6.1 → 0.6.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 15f194d4e1504310a998aeeb819e5851dea4f1f8049bf494368ad5494e611d3c
|
4
|
+
data.tar.gz: 93d8d00a95ab2436241b09253d7bb56d130122303c1e78c429cecc343d09fa82
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f7edb3c0ae40b647c03d3a70af06e08b7d1290de0326fcf34b668b08f1fb156692799e1280f4a3a17c44b9afdb18b456d949a1cc39edec396877a25a00290c8f
|
7
|
+
data.tar.gz: a169f6e4f24c9f1f4ed52e7853f00285565cfcd2aa2d8fe6049c10191dd2fcbf571c8468dea65bf6504175f1ca1ce402ad9d7353660888db2f96e57831056598
|
@@ -93,7 +93,8 @@ module MCPClient
|
|
93
93
|
|
94
94
|
@mutex.synchronize do
|
95
95
|
@consecutive_ping_failures = 0
|
96
|
-
|
96
|
+
# Reset attempt counter after a successful reconnect
|
97
|
+
@reconnect_attempts = 0
|
97
98
|
@last_activity_time = Time.now
|
98
99
|
end
|
99
100
|
rescue StandardError => e
|
@@ -48,7 +48,7 @@ module MCPClient
|
|
48
48
|
@env = env || {}
|
49
49
|
end
|
50
50
|
|
51
|
-
# Connect to the MCP server by launching the command process via stdout
|
51
|
+
# Connect to the MCP server by launching the command process via stdin/stdout
|
52
52
|
# @return [Boolean] true if connection was successful
|
53
53
|
# @raise [MCPClient::Errors::ConnectionError] if connection fails
|
54
54
|
def connect
|
@@ -58,12 +58,10 @@ module MCPClient
|
|
58
58
|
else
|
59
59
|
@stdin, @stdout, @stderr, @wait_thread = Open3.popen3(*@command_array)
|
60
60
|
end
|
61
|
+
elsif @env.any?
|
62
|
+
@stdin, @stdout, @stderr, @wait_thread = Open3.popen3(@env, @command)
|
61
63
|
else
|
62
|
-
|
63
|
-
@stdin, @stdout, @stderr, @wait_thread = Open3.popen3(@env, @command)
|
64
|
-
else
|
65
|
-
@stdin, @stdout, @stderr, @wait_thread = Open3.popen3(@command)
|
66
|
-
end
|
64
|
+
@stdin, @stdout, @stderr, @wait_thread = Open3.popen3(@command)
|
67
65
|
end
|
68
66
|
true
|
69
67
|
rescue StandardError => e
|
data/lib/mcp_client/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby-mcp-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Szymon Kurcab
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-05-
|
11
|
+
date: 2025-05-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|