Skip to content

Commit 742b2b8

Browse files
committed
chore: remove prints
1 parent de3294a commit 742b2b8

6 files changed

Lines changed: 13 additions & 26 deletions

File tree

Cargo.lock

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

program-tests/compressed-token-test/tests/transfer2/spl_ctoken.rs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -188,8 +188,10 @@ async fn test_spl_to_ctoken_transfer() {
188188

189189
#[tokio::test]
190190
async fn test_ctoken_to_spl_with_compress_and_close() {
191-
use light_compressed_token_sdk::instructions::create_ctoken_to_spl_transfer_and_close_instruction;
192-
use light_compressed_token_sdk::token_pool::find_token_pool_pda_with_index;
191+
use light_compressed_token_sdk::{
192+
instructions::create_ctoken_to_spl_transfer_and_close_instruction,
193+
token_pool::find_token_pool_pda_with_index,
194+
};
193195

194196
let mut rpc = LightProgramTest::new(ProgramTestConfig::new(true, None))
195197
.await
@@ -279,6 +281,7 @@ async fn test_ctoken_to_spl_with_compress_and_close() {
279281
let (token_pool_pda, token_pool_pda_bump) = find_token_pool_pda_with_index(&mint, 0);
280282

281283
// Create instruction using compress_and_close variant
284+
// Note: Using spl_token::ID because create_mint_helper creates Token (not Token-2022) mints
282285
let transfer_ix = create_ctoken_to_spl_transfer_and_close_instruction(
283286
associated_token_account,
284287
spl_token_account_keypair.pubkey(),
@@ -288,7 +291,7 @@ async fn test_ctoken_to_spl_with_compress_and_close() {
288291
payer.pubkey(),
289292
token_pool_pda,
290293
token_pool_pda_bump,
291-
spl_token_2022::ID,
294+
anchor_spl::token::ID,
292295
)
293296
.unwrap();
294297

program-tests/registry-test/tests/compressible.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ use light_test_utils::{
2020
airdrop_lamports, assert_claim::assert_claim, spl::create_mint_helper, Rpc, RpcError,
2121
};
2222
use light_token_client::actions::{
23-
create_compressible_token_account, CreateCompressibleTokenAccountInputs,
23+
create_compressible_token_account, transfer_ctoken, CreateCompressibleTokenAccountInputs,
2424
};
2525
use solana_sdk::{
2626
instruction::Instruction,
@@ -1140,7 +1140,6 @@ async fn assert_not_compressible<R: Rpc>(
11401140
#[tokio::test]
11411141
async fn test_compressible_account_infinite_funding() -> Result<(), RpcError> {
11421142
use light_test_utils::assert_ctoken_transfer::assert_ctoken_transfer;
1143-
use light_token_client::actions::ctoken_transfer;
11441143

11451144
let mut rpc = LightProgramTest::new(ProgramTestConfig::new_v2(false, None))
11461145
.await
@@ -1281,7 +1280,7 @@ async fn test_compressible_account_infinite_funding() -> Result<(), RpcError> {
12811280
};
12821281

12831282
// Transfer all tokens from source to dest
1284-
ctoken_transfer(
1283+
transfer_ctoken(
12851284
&mut rpc,
12861285
source,
12871286
dest,

programs/compressed-token/anchor/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -424,7 +424,7 @@ pub enum ErrorCode {
424424
MintActionInvalidCpiContextAddressTreePubkey,
425425
#[msg("CompressAndClose: Cannot use the same compressed output account for multiple closures")]
426426
CompressAndCloseDuplicateOutput,
427-
#[msg("CompressAndClose by rent authority requires compressed token account in outputs")]
427+
#[msg("CompressAndClose by compression authority requires compressed token account in outputs")]
428428
CompressAndCloseOutputMissing,
429429
}
430430

programs/compressed-token/program/src/transfer2/compression/spl.rs

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -77,13 +77,6 @@ fn spl_token_transfer_invoke_cpi(
7777
cpi_authority: &AccountInfo,
7878
amount: u64,
7979
) -> Result<(), ProgramError> {
80-
msg!("spl_token_transfer_invoke_cpi");
81-
msg!(
82-
"from {:?}",
83-
solana_pubkey::Pubkey::new_from_array(*from.key())
84-
);
85-
msg!("to {:?}", solana_pubkey::Pubkey::new_from_array(*to.key()));
86-
msg!("amount {:?}", amount);
8780
let bump_seed = [BUMP_CPI_AUTHORITY];
8881
let seed_array = [
8982
Seed::from(CPI_AUTHORITY_PDA_SEED),
@@ -110,13 +103,6 @@ fn spl_token_transfer_invoke(
110103
authority: &AccountInfo,
111104
amount: u64,
112105
) -> Result<(), ProgramError> {
113-
msg!("spl_token_transfer_invoke");
114-
msg!(
115-
"from {:?}",
116-
solana_pubkey::Pubkey::new_from_array(*from.key())
117-
);
118-
msg!("to {:?}", solana_pubkey::Pubkey::new_from_array(*to.key()));
119-
msg!("amount {:?}", amount);
120106
spl_token_transfer_common(program_id, from, to, authority, amount, None)
121107
}
122108

sdk-libs/compressed-token-sdk/src/instructions/mod.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,8 @@ pub use mint_to_compressed::{
5454
};
5555
pub use transfer_ctoken::{transfer_ctoken, transfer_ctoken_signed};
5656
pub use transfer_interface::{
57-
create_ctoken_to_spl_transfer_and_close_instruction,
58-
create_transfer_ctoken_to_spl_instruction, create_transfer_spl_to_ctoken_instruction,
59-
transfer_interface, transfer_interface_signed,
57+
create_ctoken_to_spl_transfer_and_close_instruction, create_transfer_ctoken_to_spl_instruction,
58+
create_transfer_spl_to_ctoken_instruction, transfer_interface, transfer_interface_signed,
6059
};
6160
pub use update_compressed_mint::{
6261
update_compressed_mint, update_compressed_mint_cpi, UpdateCompressedMintInputs,

0 commit comments

Comments
 (0)