Skip to content

Commit

Permalink
remove solana-program from solana-vote-program (#4536)
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinheavey authored Jan 20, 2025
1 parent 2d2bc71 commit f19a680
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 17 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

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

2 changes: 1 addition & 1 deletion programs/sbf/Cargo.lock

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

8 changes: 4 additions & 4 deletions programs/vote/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,15 +32,15 @@ solana-instruction = { workspace = true }
solana-keypair = { workspace = true }
solana-metrics = { workspace = true, optional = true }
solana-packet = { workspace = true }
solana-program = { workspace = true }
solana-program-runtime = { workspace = true }
solana-pubkey = { workspace = true }
solana-pubkey = { workspace = true, features = ["curve25519"] }
solana-rent = { workspace = true }
solana-sdk-ids = { workspace = true }
solana-signer = { workspace = true }
solana-slot-hashes = { workspace = true }
solana-transaction = { workspace = true, features = ["bincode"] }
solana-transaction-context = { workspace = true, features = ["bincode"] }
solana-vote-interface = { workspace = true, features = ["bincode"] }
thiserror = { workspace = true }

[dev-dependencies]
Expand All @@ -62,8 +62,8 @@ default = ["metrics"]
frozen-abi = [
"dep:solana-frozen-abi",
"dep:solana-frozen-abi-macro",
"solana-program/frozen-abi",
"solana-program-runtime/frozen-abi"
"solana-program-runtime/frozen-abi",
"solana-vote-interface/frozen-abi"
]
metrics = ["dep:solana-metrics"]

Expand Down
2 changes: 1 addition & 1 deletion programs/vote/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ extern crate solana_metrics;
#[cfg(feature = "frozen-abi")]
extern crate solana_frozen_abi_macro;

pub use solana_program::vote::{
pub use solana_vote_interface::{
authorized_voters, error as vote_error, instruction as vote_instruction,
program::{check_id, id},
};
4 changes: 2 additions & 2 deletions programs/vote/src/vote_processor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ use {
solana_bincode::limited_deserialize,
solana_feature_set as feature_set,
solana_instruction::error::InstructionError,
solana_program::vote::{instruction::VoteInstruction, program::id, state::VoteAuthorize},
solana_program_runtime::{
declare_process_instruction, invoke_context::InvokeContext,
sysvar_cache::get_sysvar_with_account_check,
},
solana_pubkey::Pubkey,
solana_transaction_context::{BorrowedAccount, InstructionContext, TransactionContext},
solana_vote_interface::{instruction::VoteInstruction, program::id, state::VoteAuthorize},
std::collections::HashSet,
};

Expand Down Expand Up @@ -276,12 +276,12 @@ mod tests {
solana_epoch_schedule::EpochSchedule,
solana_hash::Hash,
solana_instruction::{AccountMeta, Instruction},
solana_program::vote::instruction::{tower_sync, tower_sync_switch},
solana_program_runtime::invoke_context::mock_process_instruction,
solana_pubkey::Pubkey,
solana_rent::Rent,
solana_sdk_ids::sysvar,
solana_slot_hashes::SlotHashes,
solana_vote_interface::instruction::{tower_sync, tower_sync_switch},
std::{collections::HashSet, str::FromStr},
};

Expand Down
4 changes: 2 additions & 2 deletions programs/vote/src/vote_state/mod.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! Vote state, vote program
//! Receive and processes votes from validators
pub use solana_program::vote::state::{vote_state_versions::*, *};
pub use solana_vote_interface::state::{vote_state_versions::*, *};
use {
log::*,
serde_derive::{Deserialize, Serialize},
Expand All @@ -10,13 +10,13 @@ use {
solana_feature_set::{self as feature_set, FeatureSet},
solana_hash::Hash,
solana_instruction::error::InstructionError,
solana_program::vote::{error::VoteError, program::id},
solana_pubkey::Pubkey,
solana_rent::Rent,
solana_slot_hashes::SlotHash,
solana_transaction_context::{
BorrowedAccount, IndexOfAccount, InstructionContext, TransactionContext,
},
solana_vote_interface::{error::VoteError, program::id},
std::{
cmp::Ordering,
collections::{HashSet, VecDeque},
Expand Down
8 changes: 4 additions & 4 deletions programs/vote/src/vote_transaction.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ use {
solana_clock::Slot,
solana_hash::Hash,
solana_keypair::Keypair,
solana_program::vote::{
self,
state::{TowerSync, Vote, VoteStateUpdate},
},
solana_signer::Signer,
solana_transaction::Transaction,
solana_vote_interface::{
self as vote,
state::{TowerSync, Vote, VoteStateUpdate},
},
};

pub fn new_vote_transaction(
Expand Down
3 changes: 2 additions & 1 deletion sdk/vote-interface/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,8 @@ frozen-abi = [
"dep:solana-frozen-abi-macro",
"serde",
"solana-hash/frozen-abi",
"solana-pubkey/frozen-abi"
"solana-pubkey/frozen-abi",
"solana-short-vec/frozen-abi",
]
serde = [
"dep:serde",
Expand Down
2 changes: 1 addition & 1 deletion svm/examples/Cargo.lock

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

0 comments on commit f19a680

Please sign in to comment.