Skip to content
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

blockchain: demote BIP 9 log statements #1832

Merged
merged 1 commit into from
Mar 18, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions blockchain/thresholdstate.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ func thresholdStateTransition(state ThresholdState, prevNode *blockNode,
// speed deployments can only transition to failed
// after a confirmation window.
if !checker.IsSpeedy() && checker.HasEnded(prevNode) {
log.Infof("Moving from state=%v, to state=%v", state,
log.Debugf("Moving from state=%v, to state=%v", state,
ThresholdFailed)

state = ThresholdFailed
Expand All @@ -182,7 +182,7 @@ func thresholdStateTransition(state ThresholdState, prevNode *blockNode,
// once its start time has been reached (and it hasn't
// already expired per the above).
if checker.HasStarted(prevNode) {
log.Infof("Moving from state=%v, to state=%v", state,
log.Debugf("Moving from state=%v, to state=%v", state,
ThresholdStarted)

state = ThresholdStarted
Expand All @@ -193,7 +193,7 @@ func thresholdStateTransition(state ThresholdState, prevNode *blockNode,
// expires before it is accepted and locked in, but
// only if this deployment isn't speedy.
if !checker.IsSpeedy() && checker.HasEnded(prevNode) {
log.Infof("Moving from state=%v, to state=%v", state,
log.Debugf("Moving from state=%v, to state=%v", state,
ThresholdFailed)

state = ThresholdFailed
Expand Down Expand Up @@ -223,7 +223,7 @@ func thresholdStateTransition(state ThresholdState, prevNode *blockNode,
// period that voted for the rule change meets the
// activation threshold.
case count >= checker.RuleChangeActivationThreshold():
log.Infof("Moving from state=%v, to state=%v", state,
log.Debugf("Moving from state=%v, to state=%v", state,
ThresholdLockedIn)

state = ThresholdLockedIn
Expand All @@ -232,13 +232,13 @@ func thresholdStateTransition(state ThresholdState, prevNode *blockNode,
// threshold above, and the deployment has expired, then
// we transition to failed.
case checker.IsSpeedy() && checker.HasEnded(prevNode):
log.Infof("Moving from state=%v, to state=%v", state,
log.Debugf("Moving from state=%v, to state=%v", state,
ThresholdFailed)

state = ThresholdFailed

default:
log.Infof("Still at state=%v, threshold=%v", state,
log.Tracef("Still at state=%v, threshold=%v", state,
float64(count)/float64(checker.RuleChangeActivationThreshold()))
}

Expand All @@ -251,12 +251,12 @@ func thresholdStateTransition(state ThresholdState, prevNode *blockNode,
// If we aren't eligible to active yet, then we'll just
// stay in the locked in position.
if !checker.EligibleToActivate(prevNode) {
log.Infof("Moving from state=%v, to state=%v", state,
log.Debugf("Moving from state=%v, to state=%v", state,
ThresholdLockedIn)

state = ThresholdLockedIn
} else {
log.Infof("Moving from state=%v, to state=%v", state,
log.Debugf("Moving from state=%v, to state=%v", state,
ThresholdActive)

// The new rule becomes active when its
Expand Down