Skip to content

Commit

Permalink
make bank_client optional in tps-client
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinheavey committed Jan 11, 2025
1 parent de754be commit ef850cd
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
9 changes: 7 additions & 2 deletions tps-client/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ edition = { workspace = true }
log = { workspace = true }
solana-account = { workspace = true }
solana-client = { workspace = true }
solana-client-traits = { workspace = true }
solana-client-traits = { workspace = true, optional = true }
solana-clock = { workspace = true }
solana-commitment-config = { workspace = true }
solana-connection-cache = { workspace = true }
Expand All @@ -24,7 +24,7 @@ solana-pubkey = { workspace = true }
solana-quic-client = { workspace = true }
solana-rpc-client = { workspace = true }
solana-rpc-client-api = { workspace = true }
solana-runtime = { workspace = true }
solana-runtime = { workspace = true, optional = true }
solana-signature = { workspace = true }
solana-signer = { workspace = true }
solana-streamer = { workspace = true }
Expand All @@ -42,3 +42,8 @@ tempfile = { workspace = true }

[package.metadata.docs.rs]
targets = ["x86_64-unknown-linux-gnu"]
all-features = true
rustdoc-args = ["--cfg=docsrs"]

[features]
bank-client = ["dep:solana-client-traits", "dep:solana-runtime"]
2 changes: 2 additions & 0 deletions tps-client/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
use {
log::debug,
solana_account::Account,
Expand Down Expand Up @@ -140,6 +141,7 @@ pub trait TpsClient {
) -> TpsClientResult<UiConfirmedBlock>;
}

#[cfg(feature = "bank-client")]
mod bank_client;
mod rpc_client;
mod tpu_client;
Expand Down

0 comments on commit ef850cd

Please sign in to comment.