Skip to content

Commit

Permalink
remove some generated_from_seed_indexed()
Browse files Browse the repository at this point in the history
  • Loading branch information
dailinsubjam committed Oct 12, 2023
1 parent 3fc6194 commit 134d39a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions crates/hotshot/examples/infra/modDA.rs
Original file line number Diff line number Diff line change
Expand Up @@ -680,8 +680,7 @@ where
let mut all_keys = BTreeSet::new();
let mut da_keys = BTreeSet::new();
for i in 0..config.config.total_nodes.get() as u64 {
let privkey = TYPES::SignatureKey::generated_from_seed_indexed([0u8; 32], i).1;
let pubkey = TYPES::SignatureKey::from_private(&privkey);
let pubkey = TYPES::SignatureKey::get_public_key(config.config.known_nodes_with_stake.get(&i).unwrap());
if i < config.config.da_committee_size as u64 {
da_keys.insert(pubkey.clone());
}
Expand Down
2 changes: 1 addition & 1 deletion crates/testing/src/task_helpers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ pub async fn build_system_handle(
let known_nodes_with_stake = config.known_nodes_with_stake.clone();
let private_key =
<BLSPubKey as SignatureKey>::generated_from_seed_indexed([0u8; 32], node_id).1;
let public_key = <SequencingTestTypes as NodeType>::SignatureKey::from_private(&private_key);
let public_key = <BLSPubKey as SignatureKey>::get_public_key(config.known_nodes_with_stake.get(node_id as usize).unwrap());
let quorum_election_config = config.election_config.clone().unwrap_or_else(|| {
<QuorumEx<SequencingTestTypes, SequencingMemoryImpl> as ConsensusExchange<
SequencingTestTypes,
Expand Down

0 comments on commit 134d39a

Please sign in to comment.