2 releases
0.1.16-alpha.0 | Apr 2, 2023 |
---|---|
0.1.12-alpha.0 | Jan 21, 2023 |
#234 in #help
Used in bitcoin-top
555KB
2K
SLoC
Description for bitcoin-deployment
Short Description
The bitcoin-deployment
crate is a direct
translation from the Bitcoin Core codebase to
Rust. It provides information and utilities for
Bitcoin soft forks and deployment parameters.
Long Description
The bitcoin-deployment
crate is a subcomponent
of the Bitcoin system, providing support for soft
forks and deployment parameters. It includes
several types, such as VBDeploymentInfo
, which
provides information about a specific deployment,
including its name and status; and
DeploymentState
, which tracks the current
deployment state for a given block height.
One important function provided by this crate is
deployment_enabled_with_buried_deployment
, which
checks if a specific deployment is currently
enabled according to a buried deployment. Another
is deployment_enabled_with_deployment_pos
, which
checks if a specific deployment is currently
enabled according to the current deployment state.
Other functions provided by this crate include
is_minimum_deployment_heightincb_for_buried_deployment
,
which determines if a given block height meets the
minimum threshold for a buried deployment; and
is_minimum_deployment_testdummy_for_deployment_pos
,
which determines if a given deployment position
meets the minimum threshold for a deployment.
Overall, the bitcoin-deployment
crate is
a useful tool for developers working with the
Bitcoin system and its soft forks, providing
information and utilities for managing deployment
parameters and states.
Relevant Mathematics
There is no significant mathematical analysis required for this crate.
88> what are the deployment parameters?
The deployment parameters refer to various rules and features that are activated or deactivated in the Bitcoin network based on specific block heights. These parameters are defined and managed by the Bitcoin Core development team, and changes to these parameters are proposed and approved through a consensus mechanism among the Bitcoin community.
Some examples of deployment parameters include:
-
BIP9: a system for deploying soft forks that allows miners and nodes to signal their support for a particular rule change before it is activated.
-
Segregated Witness (SegWit): a soft fork deployment that was activated in August 2017 to improve transaction malleability and increase block size limit.
-
Taproot: a proposed soft fork deployment that aims to improve privacy and scalability in Bitcoin transactions.
The deployment parameters are specified in the
Bitcoin Core software, and nodes running the
software will enforce the rules specified in the
deployment parameters at the appropriate block
heights. The bitcoin-deployment
crate provides
tools for managing and querying these deployment
parameters in the Bitcoin network.
89> so, a deployment is basically a selection of which version of the software protocol we will participate in. is this correct?
Yes, that's correct. A deployment is a decision to activate a certain feature or change in the software protocol, and it involves setting a specific block height at which the change will be enforced. Once that block height is reached, all nodes on the network are expected to enforce the new rules of the updated protocol.
Dependencies
~95MB
~864K SLoC