Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

[workspace]
members = [
"account-decoder",
Expand Down Expand Up @@ -538,7 +537,7 @@ solana-tps-client = { path = "tps-client", version = "=2.3.1" }
solana-tpu-client = { path = "tpu-client", version = "=2.3.1", default-features = false }
solana-tpu-client-next = { path = "tpu-client-next", version = "=2.3.1" }
solana-transaction = "2.2.2"
solana-transaction-context = { path = "transaction-context", version = "=2.3.1", features = ["bincode", "debug-signature"] }
solana-transaction-context = { path = "transaction-context", version = "=2.3.1", features = ["bincode"] }
solana-transaction-error = "2.2.1"
solana-transaction-metrics-tracker = { path = "transaction-metrics-tracker", version = "=2.3.1" }
solana-transaction-status = { path = "transaction-status", version = "=2.3.1" }
Expand Down
1 change: 0 additions & 1 deletion programs/sbf/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 2 additions & 5 deletions svm/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,6 @@ solana-type-overrides = { workspace = true }
spl-generic-token = { workspace = true }
thiserror = { workspace = true }

[target.'cfg(debug_assertions)'.dependencies]
solana-transaction-context = { workspace = true, features = ["debug-signature"] }

[dev-dependencies]
agave-feature-set = { workspace = true }
agave-reserved-account-keys = { workspace = true }
Expand All @@ -108,12 +105,12 @@ solana-logger = { workspace = true }
solana-native-token = { workspace = true }
solana-precompile-error = { workspace = true }
solana-program-runtime = { workspace = true, features = ["dev-context-only-utils"] }
solana-pubkey = { workspace = true, features = [ "rand" ] }
solana-pubkey = { workspace = true, features = ["rand"] }
solana-rent = { workspace = true }
solana-sbpf = { workspace = true }
solana-secp256k1-program = { workspace = true }
solana-secp256r1-program = { workspace = true, features = ["openssl-vendored"] }
solana-signature = { workspace = true, features = [ "rand" ] }
solana-signature = { workspace = true, features = ["rand"] }
Comment on lines -111 to +113
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this cargo fmt or cargo sort being "helpful"?

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup, I ran cargo fmt

solana-signer = { workspace = true }
# See order-crates-for-publishing.py for using this unusual `path = "."`
solana-svm = { path = ".", features = ["dev-context-only-utils", "svm-internal"] }
Expand Down
1 change: 0 additions & 1 deletion svm/examples/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions svm/src/transaction_processor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -860,8 +860,6 @@ impl<FG: ForkGraph> TransactionBatchProcessor<FG> {
.feature_set
.remove_accounts_executable_flag_checks,
);
#[cfg(debug_assertions)]
transaction_context.set_signature(tx.signature());

let pre_account_state_info =
TransactionAccountStateInfo::new(&transaction_context, tx, rent_collector);
Expand Down
7 changes: 1 addition & 6 deletions transaction-context/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,7 @@ rustdoc-args = ["--cfg=docsrs"]

[features]
bincode = ["dep:bincode", "serde", "solana-account/bincode"]
debug-signature = ["dep:solana-signature"]
dev-context-only-utils = [
"bincode",
"debug-signature",
"solana-account/dev-context-only-utils",
]
dev-context-only-utils = ["bincode", "solana-account/dev-context-only-utils"]
serde = ["dep:serde", "dep:serde_derive"]

[dependencies]
Expand Down
39 changes: 0 additions & 39 deletions transaction-context/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,6 @@
#![deny(clippy::indexing_slicing)]
#![cfg_attr(docsrs, feature(doc_auto_cfg))]

#[cfg(all(
not(target_os = "solana"),
feature = "debug-signature",
debug_assertions
))]
use solana_signature::Signature;
#[cfg(not(target_os = "solana"))]
use {solana_account::WritableAccount, solana_rent::Rent, std::mem::MaybeUninit};
use {
Expand Down Expand Up @@ -177,13 +171,6 @@ pub struct TransactionContext {
remove_accounts_executable_flag_checks: bool,
#[cfg(not(target_os = "solana"))]
rent: Rent,
/// Useful for debugging to filter by or to look it up on the explorer
#[cfg(all(
not(target_os = "solana"),
feature = "debug-signature",
debug_assertions
))]
signature: Signature,
}

impl TransactionContext {
Expand All @@ -210,12 +197,6 @@ impl TransactionContext {
return_data: TransactionReturnData::default(),
remove_accounts_executable_flag_checks: true,
rent,
#[cfg(all(
not(target_os = "solana"),
feature = "debug-signature",
debug_assertions
))]
signature: Signature::default(),
}
}

Expand Down Expand Up @@ -244,26 +225,6 @@ impl TransactionContext {
&self.accounts
}

/// Stores the signature of the current transaction
#[cfg(all(
not(target_os = "solana"),
feature = "debug-signature",
debug_assertions
))]
pub fn set_signature(&mut self, signature: &Signature) {
self.signature = *signature;
}

/// Returns the signature of the current transaction
#[cfg(all(
not(target_os = "solana"),
feature = "debug-signature",
debug_assertions
))]
pub fn get_signature(&self) -> &Signature {
&self.signature
}

/// Returns the total number of accounts loaded in this Transaction
pub fn get_number_of_accounts(&self) -> IndexOfAccount {
self.accounts.len() as IndexOfAccount
Expand Down
Loading