-
Notifications
You must be signed in to change notification settings - Fork 108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add(consensus): Adds disable_pow
and genesis_hash
fields, converts equihash::Solution
to an enum
#8421
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…pdates production code.
…rts` and `transparent::Address`
…orkKind` as zebra_network::Config::network field type, and converts 'Network' to `NetworkKind` before serializing
…l for zcash_primitives::consensus::Network
Co-authored-by: Marek <[email protected]>
…red configs can be parsed, adds an intermediate representation of activation heights
…rk where there were conversions
…serde(default)] - Panics if a non-zero activation height is provided for the `Genesis` network upgrade - Always sets the `Genesis` and `BeforeOverwinter` network upgrade activation heights to 0 and 1, `BeforeOverwinter` could be overwritten by a later network upgrade - Makes the `activation_heights` field on `Parameters` private, adds/uses an accessor method instead, and adds a builder struct and `build()` method
… the next NetworkUpgrade if it doesn't find the activation height of `&self`
… assertion message
…r how activation heights can be configured
…s test, moves struct with activation heights outside deserialization impl and accepts it in `ParametersBuilder::activation_heights()` instead of a Vec
This was
linked to
issues
Apr 22, 2024
arya2
commented
Apr 22, 2024
… configured testnets too
arya2
force-pushed
the
params-genesis-hash
branch
from
April 22, 2024 23:51
622293f
to
d4f6a0e
Compare
upbqdn
approved these changes
Apr 23, 2024
arya2
force-pushed
the
params-genesis-hash
branch
from
April 23, 2024 23:47
b7ddb90
to
0f91dd0
Compare
upbqdn
previously approved these changes
Apr 24, 2024
upbqdn
reviewed
Apr 24, 2024
Looks like a test failed due to a port conflict: https://github.com/ZcashFoundation/zebra/actions/runs/8820097707/job/24212898628?pr=8421#step:12:2817 I'll re-run it once the rest of the workflow is done. |
upbqdn
approved these changes
Apr 25, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
A-consensus
Area: Consensus rule updates
A-network
Area: Network protocol updates or fixes
C-enhancement
Category: This is an improvement
C-feature
Category: New features
C-testing
Category: These are tests
NU-6
Network Upgrade: NU6 specific tasks
P-Medium ⚡
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
We want to support Regtest in Zebra by committing the Regtest genesis block.
Closes #8412.
Closes #8366.
Closes #8362.
Closes #7846.
Depends-On: #8413.
PR Author Checklist
Check before marking the PR as ready for review:
For significant changes:
If a checkbox isn't relevant to the PR, mark it as done.
Solution
genesis_hash
anddisable_pow
fieldsequihash::Solution
to an enum to represent the smaller solutions for RegtestNetwork::checkpoint_list()
method to return the genesis checkpoint for RegtestRelated Cleanups:
CheckpointList::from_list()
toNetwork::checkpoint_list()
and check that its the first item in the checkpoints that's the genesis hash rather than the first item in theBTreeMap
.Testing
Review
Anyone can review.
Reviewer Checklist
Check before approving the PR:
PR blockers can be dealt with in new tickets or PRs.
And check the PR Author checklist is complete.
Follow Up Work
target_difficulty_limit
field totestnet::Parameters
and set it asU256::from_big_endian(&[0x0f].repeat(8))
for Regtest