Skip to content

Commit

Permalink
Misc fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
kayibal committed Dec 12, 2024
1 parent 65004a6 commit 3c9e182
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 9 deletions.
Empty file.
Empty file.
17 changes: 8 additions & 9 deletions examples/explorer/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ use clap::Parser;
use futures::{future::select_all, StreamExt};
use std::env;
use tokio::{sync::mpsc, task::JoinHandle};
use tracing_subscriber::{fmt, EnvFilter};
use tycho_client::feed::component_tracker::ComponentFilter;
use tycho_core::dto::Chain;
use tycho_simulation::{
Expand Down Expand Up @@ -38,7 +37,7 @@ async fn main() {
let cli = Cli::parse();

let tycho_url =
env::var("TYCHO_URL").unwrap_or_else(|_| "tycho-beta.propellerheads.xyz".to_string());
env::var("TYCHO_URL").unwrap_or_else(|_| "tycho-dev.propellerheads.xyz".to_string());
let tycho_api_key: String =
env::var("TYCHO_API_KEY").unwrap_or_else(|_| "sampletoken".to_string());

Expand All @@ -49,18 +48,18 @@ async fn main() {
let all_tokens = load_all_tokens(tycho_url.as_str(), Some(tycho_api_key.as_str())).await;
let tvl_filter = ComponentFilter::with_tvl_range(cli.tvl_threshold, cli.tvl_threshold);
let mut protocol_stream = ProtocolStreamBuilder::new(&tycho_url, Chain::Ethereum)
// .exchange::<UniswapV2State>("uniswap_v2", tvl_filter.clone(), None)
// .exchange::<UniswapV3State>("uniswap_v3", tvl_filter.clone(), None)
.exchange::<UniswapV2State>("uniswap_v2", tvl_filter.clone(), None)
.exchange::<UniswapV3State>("uniswap_v3", tvl_filter.clone(), None)
.exchange::<EVMPoolState<PreCachedDB>>(
"vm:balancer_v2",
tvl_filter.clone(),
Some(balancer_pool_filter),
)
.exchange::<EVMPoolState<PreCachedDB>>(
"vm:curve",
tvl_filter.clone(),
Some(curve_pool_filter),
)
// .exchange::<EVMPoolState<PreCachedDB>>(
// "vm:curve",
// tvl_filter.clone(),
// Some(curve_pool_filter),
// )
.auth_key(Some(tycho_api_key.clone()))
.set_tokens(all_tokens)
.build()
Expand Down

0 comments on commit 3c9e182

Please sign in to comment.