Commit Graph

21796 Commits

Author SHA1 Message Date
Jacinta Ferrant
5d129c8189 Fix copyright and logging and add todos where missing
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
48a4e08691 Fix missing transactions test and add TODOs for cleaning up logic
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
5ad797514e Fix transaction logic and fix block proposal test
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
e49764f33c Fix nonce retrieval and pox consensus tests
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
406c44244c Update contract calls and update signer state when a nonce request is stashed
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
7784cafdee Update coordinator id only once per run loop
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
2a4311bde3 Cleanup coordinator selector
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
784a0f35fc CRC: add mainnet var and check transaction is on the correct network when filtering signer transactions
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
a57e431867 Cleanup reward cycle config into signer config
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
21c6fe0bf6 Temp fix to prevent multipel coordinators squashing each other
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
89541b25cd Fix dkg and sign test
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
63cca9ca47 Broadcast DKG result to stackerdb for all pox-4 epochs. Do not have a fee for eppch 3 onwards
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
2c0e4bc2fc CRC: do not need to store signer_set
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
676914dea1 WIP: add logic for preventing clogging the block space
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
a10044ea20 Fix epoch 3 reward set calculation block height
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
c078c09fce Fix logging about reward registration
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
c8c19bb75c Fix nakamoto integration stacking in advance to epoch 3 reward set
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Aaron Blankstein
4dc153deb6 fix: test nakamoto nodes should use the right .signers stackerdbs 2024-02-22 21:57:59 -05:00
Jacinta Ferrant
089be91018 WIP: Get miners to retrieve transactions from stackerdb
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
454ab73eb5 Check the front of commands not the back before adding another DKG command to the front
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
4c996c38af Do not run dkg if already have a pending vote
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
2d412b8e64 Cleanup
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
b9eef9478e Fix cast aggregate public key vote transaction
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
84e25676e2 Compare prepare phase start with burn block height
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
6ae69a8abe Do not overwrite aggregate key if none. May have delay between cast and contract setting of aggregate key
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
e8f6aa14f2 Fix tests
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jude Nelson
a392e3a068 chore: fix /v2/pox to report epochs and use StacksEpochId 2024-02-22 21:57:59 -05:00
Jacinta Ferrant
2d92d54426 Rely on signers to run DKG
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
7fcbd78796 Fix get_reward_cycle_config to track the specific signer's key ids
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
0867611c62 Move signers key ids calc to get_reward_cycle_config
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
93908eace1 Fix get_reward_cycle_config by adding missing signers addition
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
d2862ce22d Fix infinite waiting for next reward cycle
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
10e9bdc71d Pass a reference to stacks client to the sub signers
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
f1a7a32c37 Parse msg id and signer set out of the event conract id
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
ce6be78213 Run DKG even if out of vote window
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
42b7342f49 Fix get stackers response
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
6d352deecb Fix relative path for reward set
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
7ce63b243c Cleanup logging
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
c4b5eceb29 Convert client error to transient where approproiate
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
f3c444efb7 CRC: rename Config to GlobalConfig and StacksNodeInfo to RewardCycleConfig
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
e15335d577 Do not process commands if you are not the coordinator
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
84d51795cc CRC: cleanup comments and var names
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
48d503fe55 CRC: cleanup tests
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
395f84efdb Fix tests compilation
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
32f407a015 Add Signer struct to handle multiple reward cycles
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jacinta Ferrant
04f1a211e7 WIP: Add cast_aggregate_public_key_vote function to stacks_client
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:57:59 -05:00
Jeff Bencin
3b8e97a58a feat: Add --prefix and --last flags to replay-block 2024-02-22 21:57:59 -05:00
Aaron Blankstein
e265679cbc skip blocks without microblock data or parent header info 2024-02-22 21:57:59 -05:00
Aaron Blankstein
9c430dc12c allow replay-block to use a block prefix 2024-02-22 21:57:59 -05:00
Aaron Blankstein
96edfb4002 working replay-block command 2024-02-22 21:57:59 -05:00