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

[Signer] Bug in reward cycle reporting #5507

Closed
jferrant opened this issue Nov 27, 2024 · 3 comments
Closed

[Signer] Bug in reward cycle reporting #5507

jferrant opened this issue Nov 27, 2024 · 3 comments
Assignees

Comments

@jferrant
Copy link
Collaborator

A user that is running multiple signers is reporting two different reward cycles. Though both signers are signing correctly, there is something wrong with the logging of one of the signer's reward cycle. Both were signers in reward cycle 97, and both are now signing in reward cycle 98. However, one is misreporting its cycle as 97 still. See the following logs:

INFO [1732674001.976314] [stacks-signer/src/v0/signer.rs:357] [signer_runloop:30000] Cycle #98 Signer #4: received a block proposal for a new block. Submit block for validation. , signer_sighash: 37c1b2c64f56055df99daa910c637dcc220cf48ab72e4ba1a5045b60e9c21fda, block_id: 515f16308add10119b273d9e1be4f156c45224bfd43f3b8e7fb480dfa6858d22, block_height: 264671, burn_height: 872142
WARN [1732674002.381521] [stacks-signer/src/chainstate.rs:524] [signer_runloop:30000] Miner's block proposal does not confirm as many blocks as we expect, proposed_block_consensus_hash: 9ed52098c0de968b01524d9e441cecdedf6eb299, proposed_block_signer_sighash: 37c1b2c64f56055df99daa910c637dcc220cf48ab72e4ba1a5045b60e9c21fda, proposed_chain_length: 264671, expected_at_least: 264672
WARN [1732674002.381534] [stacks-signer/src/v0/signer.rs:407] [signer_runloop:30000] Cycle #98 Signer #4: Block proposal invalid, signer_sighash: 37c1b2c64f56055df99daa910c637dcc220cf48ab72e4ba1a5045b60e9c21fda, block_id: 515f16308add10119b273d9e1be4f156c45224bfd43f3b8e7fb480dfa6858d22
INFO [1732674266.895256] [stacks-signer/src/runloop.rs:365] [signer_runloop:30000] Refreshing runloop with new burn block event, latest_node_burn_ht: 872143, event_ht: 872143, reward_cycle_before_refresh: 98, current_reward_cycle: 98, configured_for_current: true, registered_for_current: true, configured_for_next: false, registered_for_next: false, is_in_next_prepare_phase: false
INFO [1732674267.420148] [stacks-signer/src/v0/signer.rs:227] [signer_runloop:30000] Cycle #97 Signer #3: Received a new burn block event for block height 872143
INFO [1732674267.420230] [stacks-signer/src/v0/signer.rs:227] [signer_runloop:30000] Cycle #98 Signer #4: Received a new burn block event for block height 872143
INFO [1732674271.625849] [stacks-signer/src/v0/signer.rs:357] [signer_runloop:30000] Cycle #98 Signer #4: received a block proposal for a new block. Submit block for validation. , signer_sighash: 7f44d07cdef9d9c50a730f841d2da1792f808de7303bc82a3de25833ff25d239, block_id: 3071ea634639a7ead51646ba41584eeb7349a23ab3c11342bab8c6f35271e508, block_height: 264671, burn_height: 872143
WARN [1732674272.137128] [stacks-signer/src/chainstate.rs:524] [signer_runloop:30000] Miner's block proposal does not confirm as many blocks as we expect, proposed_block_consensus_hash: 0bcf64f72822f9d15c372531b15db0df599693bd, proposed_block_signer_sighash: 7f44d07cdef9d9c50a730f841d2da1792f808de7303bc82a3de25833ff25d239, proposed_chain_length: 264671, expected_at_least: 264672
@jferrant
Copy link
Collaborator Author

Note, the problem disappeared on restart. This most likely is related to the refresh of the reward cycle view logic in the signer.

@bartoszmat
Copy link

it happened again at cycle 99:

INFO [1733833339.450460] [stacks-signer/src/v0/signer.rs:196] [signer_runloop:30000] Cycle #99 Signer #3: Got block pushed message, block_id: 9cd895346513cb3297739983569957a220161feb671b7e28d1ea1a7d073f0704, block_height: 314060, signer_sighash: f6a23caeb0660b607404c18214587eead009b9334d7fd1686ee0ebba6a655d9e

INFO [1733833339.538060] [stacks-signer/src/v0/signer.rs:196] [signer_runloop:30000] Cycle #98 Signer #4: Got block pushed message, block_id: 9cd895346513cb3297739983569957a220161feb671b7e28d1ea1a7d073f0704, block_height: 314060, signer_sighash: f6a23caeb0660b607404c18214587eead009b9334d7fd1686ee0ebba6a655d9e

@jferrant jferrant moved this from Status: 🆕 New to Status: In Review in Stacks Core Eng Dec 11, 2024
@jferrant jferrant self-assigned this Dec 11, 2024
@jferrant jferrant moved this from Status: In Review to Status: ✅ Done in Stacks Core Eng Dec 16, 2024
@blockstack-devops
Copy link
Contributor

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@stacks-network stacks-network locked as resolved and limited conversation to collaborators Dec 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
Status: Status: ✅ Done
Development

No branches or pull requests

3 participants