Commit Graph

21829 Commits

Author SHA1 Message Date
Marzi
ef5169bec0 Cargo Format 2024-02-27 10:02:37 -05:00
Marzi
f502020bea Delete UserBurnSupportOp definition and usage 2024-02-27 10:02:37 -05:00
wileyj
577b118a36 Merge pull request #4287 from stacks-network/feat/signers-cast-dkg-vote
Feat/signers cast dkg vote
2024-02-26 07:21:15 -08:00
Jacinta Ferrant
e22871d6af Send DKG and sign to all senders and remove shutdown in hanging tests
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-24 16:50:24 -05:00
Jacinta Ferrant
7dfee14faa CRC: fix faulty comments
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-24 16:49:57 -05:00
Jacinta Ferrant
0bd2ad6212 Store commands to the side in case init fails
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-24 16:49:38 -05:00
Jacinta Ferrant
9ce4f97c9f Fix epoch check
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-23 22:02:01 -05:00
Jacinta Ferrant
1384084dd1 Do not trigger DKG if we have an approved DKG key set in the contract
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-23 15:07:13 -05:00
Jacinta Ferrant
05518ad42b CRC: cleanup comments
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-23 13:49:33 -05:00
Jacinta Ferrant
6edec125ab CRC: cleanup parse_function_args
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-23 13:33:11 -05:00
Jacinta Ferrant
e24f223a98 Fix signer vote calculations into a struct
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-23 13:12:50 -05:00
Jacinta Ferrant
1de817b2f1 Fix fee calculation and always broadcast Sign errors as block rejections
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-23 10:25:39 -05:00
Jacinta Ferrant
69d25fb0dd CRC: cleanup var names and add comment to SignerMessages
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 22:02:12 -05:00
Jacinta Ferrant
66c6862ecc Move get_signer_weights function to signer_set.rs
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
0bc6442200 Fix test_make_miners_stackerdb_config by adding missing miners contract to peer config
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
838f06fda2 Fix test simple signer test by fixing contract id
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
1c8d6118c4 Fix reward cycle filter bad transactions test
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
51809a009b Fix get_current_reward_cycle in stacks client
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
e99d6d8ce2 Cleanup reward cycle transitions test
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
5149d6fcd3 Always refresh configs, temp set consenus has to 0 in coordinator calculation, retrieve NEXT signers transactions in signer
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
b0d4a34a1a Retreive the transactions from the NEXT signers in the miner
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
c0a0d74a26 Fix reward set boundary calculation
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
33a8a80787 Increase wait_for_signers timeout
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
74ec4bca4f Fix prepare phase reward set calculation
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
867198119d CRC: cleanup logging
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
9cce191a5b WIP: add test for post epoch 3 reward cycle transition
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
435e6768fd Fix rebase issue: rename of slots to weight
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
62e2109259 CRC: use signer weights when calculating block rejection thresholds
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
14a15a682d CRC: cleanup comments
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
0b08bf7d98 Fix signer slot id for index calculation in verify_payload
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
efd6352b58 If no reward set is found for a reward cycle, do not check again
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
3fa40b738a Fix verify payload test
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
Jacinta Ferrant
e4f60289e5 Fix clippy warnings in stacks signer
Signed-off-by: Jacinta Ferrant <jacinta@trustmachines.co>
2024-02-22 21:58:00 -05:00
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