Remove old crate dep
This commit is contained in:
parent
a849f8e929
commit
4d2ff19d41
1316
ext/mcp/Cargo.lock
generated
1316
ext/mcp/Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@ -11,13 +11,11 @@ path = "src/internal-test.rs"
|
|||||||
crate-type = ["cdylib"]
|
crate-type = ["cdylib"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
jsonrpsee = { version = "0.24.8", features = ["client", "tracing"] }
|
jsonrpsee = { version = "0.24.8", features = ["async-client", "client-core", "tracing"] }
|
||||||
magnus = "0.7"
|
magnus = "0.7"
|
||||||
mcp-sdk = "0.0.3"
|
|
||||||
tokio = { version = "1.44.1", features = ["full"] }
|
tokio = { version = "1.44.1", features = ["full"] }
|
||||||
anyhow = "1.0.97"
|
anyhow = "1.0.97"
|
||||||
tracing = "0.1.41"
|
tracing = "0.1.41"
|
||||||
tokio-stdin-stdout = "0.1.5"
|
|
||||||
serde = { version = "1.0.219", features = ["derive"] }
|
serde = { version = "1.0.219", features = ["derive"] }
|
||||||
serde_json = "1.0.140"
|
serde_json = "1.0.140"
|
||||||
tracing-subscriber = { version = "0.3.19", features = ["env-filter"] }
|
tracing-subscriber = { version = "0.3.19", features = ["env-filter"] }
|
||||||
|
|||||||
@ -1,5 +1,3 @@
|
|||||||
mod mcp_client;
|
|
||||||
|
|
||||||
use magnus::{function, Error, Ruby};
|
use magnus::{function, Error, Ruby};
|
||||||
|
|
||||||
fn distance(a: (f64, f64), b: (f64, f64)) -> f64 {
|
fn distance(a: (f64, f64), b: (f64, f64)) -> f64 {
|
||||||
|
|||||||
@ -1,30 +0,0 @@
|
|||||||
use std::time::Duration;
|
|
||||||
use mcp_sdk::client::ClientBuilder;
|
|
||||||
use mcp_sdk::protocol::RequestOptions;
|
|
||||||
use mcp_sdk::transport::Transport;
|
|
||||||
|
|
||||||
#[tokio::test(flavor = "multi_thread", worker_threads = 2)]
|
|
||||||
async fn test_a() {
|
|
||||||
let transport = mcp_sdk::transport::ClientStdioTransport::new(
|
|
||||||
"/Users/joshuacoles/.local/bin/mcp-server-fetch",
|
|
||||||
&[],
|
|
||||||
).unwrap();
|
|
||||||
|
|
||||||
transport.open().unwrap();
|
|
||||||
|
|
||||||
let client = ClientBuilder::new(transport).build();
|
|
||||||
let client_clone = client.clone();
|
|
||||||
|
|
||||||
let a = tokio::spawn(async move { client_clone.start().await });
|
|
||||||
let response = client
|
|
||||||
.request(
|
|
||||||
"echo",
|
|
||||||
None,
|
|
||||||
RequestOptions::default().timeout(Duration::from_secs(1)),
|
|
||||||
)
|
|
||||||
.await.unwrap();
|
|
||||||
|
|
||||||
println!("{:?}", response);
|
|
||||||
|
|
||||||
a.abort();
|
|
||||||
}
|
|
||||||
Loading…
Reference in New Issue
Block a user