feat: upgrade to v2.0.0 with major dependency updates
- Upgrade Solana dependencies from 2.3.x to 3.0.0 series - Upgrade solana-streamer-sdk from 0.4.13 to 0.5.0 - Upgrade yellowstone-grpc from 8.0.0 to 9.0.0 - Add new SPL token utility modules (spl_token.rs, spl_token_2022.rs, spl_associated_token_account.rs) - Remove deprecated gRPC protocol definitions (protos/ directory) - Remove event_subscription example and update all example dependencies - Update README documentation to reflect v2.0.0 changes - Refactor imports to use new dependency structure across examples BREAKING CHANGES: - Solana SDK upgraded to 3.0.0 with API changes - Removed gRPC protocol definitions - Updated import paths for SPL token operations
This commit is contained in:
@@ -5,7 +5,9 @@ edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
sol-trade-sdk = { path = "../.." }
|
||||
solana-sdk = "2.3.0"
|
||||
solana-streamer-sdk = "0.5.0"
|
||||
solana-sdk = "3.0.0"
|
||||
solana-commitment-config = { version = "3.0.0", features = ["serde"] }
|
||||
spl-associated-token-account = "7.0.0"
|
||||
tokio = { version = "1", features = ["full"] }
|
||||
anyhow = "1.0.94"
|
||||
|
||||
@@ -3,28 +3,25 @@ use std::sync::{
|
||||
Arc,
|
||||
};
|
||||
|
||||
use sol_trade_sdk::solana_streamer_sdk::streaming::event_parser::common::EventType;
|
||||
use sol_trade_sdk::solana_streamer_sdk::streaming::event_parser::protocols::pumpfun::PumpFunTradeEvent;
|
||||
use sol_trade_sdk::solana_streamer_sdk::streaming::event_parser::{Protocol, UnifiedEvent};
|
||||
use sol_trade_sdk::solana_streamer_sdk::streaming::yellowstone_grpc::{
|
||||
AccountFilter, TransactionFilter,
|
||||
};
|
||||
use sol_trade_sdk::solana_streamer_sdk::streaming::YellowstoneGrpc;
|
||||
use sol_trade_sdk::{
|
||||
common::nonce_cache::NonceCache,
|
||||
solana_streamer_sdk::streaming::event_parser::protocols::pumpfun::parser::PUMPFUN_PROGRAM_ID,
|
||||
};
|
||||
use sol_trade_sdk::common::nonce_cache::NonceCache;
|
||||
use sol_trade_sdk::common::TradeConfig;
|
||||
use sol_trade_sdk::TradeTokenType;
|
||||
use sol_trade_sdk::{
|
||||
common::AnyResult,
|
||||
swqos::SwqosConfig,
|
||||
trading::{core::params::PumpFunParams, factory::DexType},
|
||||
SolanaTrade,
|
||||
};
|
||||
use sol_trade_sdk::{common::TradeConfig, solana_streamer_sdk::match_event};
|
||||
use sol_trade_sdk::{
|
||||
solana_streamer_sdk::streaming::event_parser::common::filter::EventTypeFilter, TradeTokenType,
|
||||
};
|
||||
use solana_sdk::{commitment_config::CommitmentConfig, signature::Keypair};
|
||||
use solana_commitment_config::CommitmentConfig;
|
||||
use solana_sdk::signature::Keypair;
|
||||
use solana_streamer_sdk::match_event;
|
||||
use solana_streamer_sdk::streaming::event_parser::common::filter::EventTypeFilter;
|
||||
use solana_streamer_sdk::streaming::event_parser::common::EventType;
|
||||
use solana_streamer_sdk::streaming::event_parser::protocols::pumpfun::parser::PUMPFUN_PROGRAM_ID;
|
||||
use solana_streamer_sdk::streaming::event_parser::protocols::pumpfun::PumpFunTradeEvent;
|
||||
use solana_streamer_sdk::streaming::event_parser::{Protocol, UnifiedEvent};
|
||||
use solana_streamer_sdk::streaming::yellowstone_grpc::{AccountFilter, TransactionFilter};
|
||||
use solana_streamer_sdk::streaming::YellowstoneGrpc;
|
||||
|
||||
// Global static flag to ensure transaction is executed only once
|
||||
static ALREADY_EXECUTED: AtomicBool = AtomicBool::new(false);
|
||||
|
||||
Reference in New Issue
Block a user