Skip to content

Commit a63481f

Browse files
authored
SPL: Use spl-instruction-padding-interface crate (#7275)
#### Problem As outlined in #7256, we need to get Agave off of crates that depend back on Agave. spl-instruction-padding is one of those crates #### Summary of changes Use spl-instruction-padding-interface instead. Everything else is exactly the same.
1 parent 0c42e18 commit a63481f

File tree

6 files changed

+14
-15
lines changed

6 files changed

+14
-15
lines changed

Cargo.lock

Lines changed: 4 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -564,7 +564,6 @@ solana-zk-token-proof-program = { path = "programs/zk-token-proof", version = "=
564564
solana-zk-token-sdk = { path = "zk-token-sdk", version = "=3.0.0" }
565565
spl-associated-token-account-interface = "1.0.0"
566566
spl-generic-token = "1.0.1"
567-
spl-instruction-padding = "0.3.0"
568567
spl-memo = "6.0.0"
569568
spl-pod = "0.5.1"
570569
spl-token = "8.0.0"

bench-tps/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ solana-tpu-client = { workspace = true }
6767
solana-transaction = { workspace = true }
6868
solana-transaction-status = { workspace = true }
6969
solana-version = { workspace = true }
70-
spl-instruction-padding = { version = "=0.3.0", features = ["no-entrypoint"] }
70+
spl-instruction-padding-interface = { version = "=0.1.0" }
7171
thiserror = { workspace = true }
7272

7373
[target.'cfg(not(any(target_env = "msvc", target_os = "freebsd")))'.dependencies]

bench-tps/src/bench.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ use {
2828
solana_time_utils::timestamp,
2929
solana_tps_client::*,
3030
solana_transaction::Transaction,
31-
spl_instruction_padding::instruction::wrap_instruction,
31+
spl_instruction_padding_interface::instruction::wrap_instruction,
3232
std::{
3333
collections::{HashSet, VecDeque},
3434
process::exit,

bench-tps/src/cli.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -599,7 +599,7 @@ pub fn parse_args(matches: &ArgMatches) -> Result<Config, &'static str> {
599599
let program_id = matches
600600
.value_of("instruction_padding_program_id")
601601
.map(|target_str| target_str.parse().unwrap())
602-
.unwrap_or_else(|| spl_instruction_padding::ID);
602+
.unwrap_or_else(|| spl_instruction_padding_interface::ID);
603603
let data_size = data_size
604604
.parse()
605605
.map_err(|_| "Can't parse padded instruction data size")?;

bench-tps/tests/bench_tps.rs

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ fn program_account(program_data: &[u8]) -> AccountSharedData {
4343
fn test_bench_tps_local_cluster(config: Config) {
4444
let native_instruction_processors = vec![];
4545
let additional_accounts = vec![(
46-
spl_instruction_padding::ID,
46+
spl_instruction_padding_interface::ID,
4747
program_account(include_bytes!("fixtures/spl_instruction_padding.so")),
4848
)];
4949

@@ -120,7 +120,10 @@ fn test_bench_tps_test_validator(config: Config) {
120120
..Rent::default()
121121
})
122122
.faucet_addr(Some(faucet_addr))
123-
.add_program("spl_instruction_padding", spl_instruction_padding::ID)
123+
.add_program(
124+
"spl_instruction_padding",
125+
spl_instruction_padding_interface::ID,
126+
)
124127
.start_with_mint_address(mint_pubkey, SocketAddrSpace::Unspecified)
125128
.expect("validator start failed");
126129

@@ -203,7 +206,7 @@ fn test_bench_tps_local_cluster_with_padding() {
203206
tx_count: 100,
204207
duration: Duration::from_secs(10),
205208
instruction_padding_config: Some(InstructionPaddingConfig {
206-
program_id: spl_instruction_padding::ID,
209+
program_id: spl_instruction_padding_interface::ID,
207210
data_size: 0,
208211
}),
209212
..Config::default()
@@ -217,7 +220,7 @@ fn test_bench_tps_tpu_client_with_padding() {
217220
tx_count: 100,
218221
duration: Duration::from_secs(10),
219222
instruction_padding_config: Some(InstructionPaddingConfig {
220-
program_id: spl_instruction_padding::ID,
223+
program_id: spl_instruction_padding_interface::ID,
221224
data_size: 0,
222225
}),
223226
..Config::default()

0 commit comments

Comments
 (0)