Skip to content

Commit

Permalink
Patch HS to include Restart Fix (#2042)
Browse files Browse the repository at this point in the history
### This PR:

This just includes a one line change in Hotshot to count Timeout votes
as an action and fixes the restart issue we saw.

### This PR does not:
<!-- Describe what is out of scope for this PR, if applicable. Leave
this section blank if it's not applicable -->
<!-- This section helps avoid the reviewer having to needlessly point
out missing parts -->
<!-- * Implement feature 3 because that feature is blocked by Issue 4
-->
<!-- * Implement xyz because that is tracked in issue #123. -->
<!-- * Address xzy for which I opened issue #456 -->

### Key places to review:
<!-- Describe key places for reviewers to pay close attention to -->
<!-- * file.rs, `add_integers` function -->
<!-- Or directly comment on those files/lines to make it easier for the
reviewers -->

<!-- ### How to test this PR:  -->
<!-- Optional, uncomment the above line if this is relevant to your PR
-->
<!-- If your PR is fully tested through CI there is no need to add this
section -->
<!-- * E.g. `just test` -->

<!-- ### Things tested -->
<!-- Anything that was manually tested (that is not tested in CI). -->
<!-- E.g. building/running of docker containers. Changes to docker demo,
... -->
<!-- Especially mention anything untested, with reasoning and link an
issue to resolve this. -->

<!-- Complete the following items before creating this PR -->
<!-- [ ] Issue linked or PR description mentions why this change is
necessary. -->
<!-- [ ] PR description is clear enough for reviewers. -->
<!-- [ ] Documentation for changes (additions) has been updated (added).
-->
<!-- [ ] If this is a draft it is marked as "draft".  -->

<!-- To make changes to this template edit
https://github.com/EspressoSystems/.github/blob/main/PULL_REQUEST_TEMPLATE.md
-->
  • Loading branch information
bfish713 authored Sep 20, 2024
2 parents 6b7e8d9 + c20a399 commit e3a8b2e
Show file tree
Hide file tree
Showing 4 changed files with 64 additions and 19 deletions.
63 changes: 49 additions & 14 deletions Cargo.lock

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

12 changes: 12 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -140,3 +140,15 @@ paste = "1.0"
rand = "0.8.5"
time = "0.3"
trait-set = "0.3.0"

[patch."https://github.com/EspressoSystems/HotShot.git"]
hotshot = { git = "https://www.github.com/EspressoSystems/HotShot.git", tag = "0.5.74-patch1" }
hotshot-builder-api = { git = "https://www.github.com/EspressoSystems/HotShot.git", tag = "0.5.74-patch1" }
hotshot-orchestrator = { git = "https://www.github.com/EspressoSystems/HotShot.git", tag = "0.5.74-patch1" }
hotshot-stake-table = { git = "https://www.github.com/EspressoSystems/HotShot.git", tag = "0.5.74-patch1" }
hotshot-task ={ git = "https://www.github.com/EspressoSystems/HotShot.git", tag = "0.5.74-patch1" }
hotshot-task-impls ={ git = "https://www.github.com/EspressoSystems/HotShot.git", tag = "0.5.74-patch1" }
hotshot-testing ={ git = "https://www.github.com/EspressoSystems/HotShot.git", tag = "0.5.74-patch1" }
hotshot-types = { git = "https://www.github.com/EspressoSystems/HotShot.git", tag = "0.5.74-patch1" }
# libp2p-networking = { git = "https://github.com/EspressoSystems/hotshot", tag = "0.5.74-patch1" }
hotshot-example-types = { git = "https://www.github.com/EspressoSystems/HotShot.git", tag = "0.5.74-patch1" }
5 changes: 2 additions & 3 deletions builder/src/permissioned.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ use hotshot::{
traits::{
election::static_committee::GeneralStaticCommittee,
implementations::{
derive_libp2p_peer_id, CdnMetricsValue, CdnTopic, CombinedNetworks, KeyPair,
Libp2pNetwork, PushCdnNetwork, WrappedSignatureKey,
derive_libp2p_peer_id, CdnMetricsValue, CdnTopic, CombinedNetworks, GossipConfig,
KeyPair, Libp2pNetwork, PushCdnNetwork, WrappedSignatureKey,
},
BlockPayload,
},
Expand Down Expand Up @@ -96,7 +96,6 @@ use hotshot_types::{
};
use jf_merkle_tree::{namespaced_merkle_tree::NamespacedMerkleTreeScheme, MerkleTreeScheme};
use jf_signature::bls_over_bn254::VerKey;
use libp2p_networking::network::GossipConfig;
use sequencer::{
catchup::StatePeers,
context::{Consensus, SequencerContext},
Expand Down
3 changes: 1 addition & 2 deletions sequencer/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ use futures::FutureExt;
use genesis::L1Finalized;
// Should move `STAKE_TABLE_CAPACITY` in the sequencer repo when we have variate stake table support
use libp2p::Multiaddr;
use libp2p_networking::network::GossipConfig;
use network::libp2p::split_off_peer_id;
use options::Identity;
use state_signature::static_stake_table_commitment;
Expand All @@ -40,7 +39,7 @@ use derivative::Derivative;
use espresso_types::v0::traits::{PersistenceOptions, SequencerPersistence};
pub use genesis::Genesis;
#[cfg(feature = "libp2p")]
use hotshot::traits::implementations::{CombinedNetworks, Libp2pNetwork};
use hotshot::traits::implementations::{CombinedNetworks, GossipConfig, Libp2pNetwork};
use hotshot::{
traits::implementations::{
derive_libp2p_peer_id, CdnMetricsValue, CdnTopic, KeyPair, MemoryNetwork, PushCdnNetwork,
Expand Down

0 comments on commit e3a8b2e

Please sign in to comment.