mirror of
https://github.com/OffchainLabs/prysm.git
synced 2026-01-08 23:18:15 -05:00
Block backfilling (#12968)
* backfill service * fix bug where origin state is never unlocked * support mvslice states * use renamed interface * refactor db code to skip block cache for backfill * lint * add test for verifier.verify * enable service in service init test * cancellation cleanup * adding nil checks to configset juggling * assume blocks are available by default As long as we're sure the AvailableBlocker is initialized correctly during node startup, defaulting to assuming we aren't in a checkpoint sync simplifies things greatly for tests. * block saving path refactor and bugfix * fix fillback test * fix BackfillStatus init tests --------- Co-authored-by: Kasey Kirkham <kasey@users.noreply.github.com>
This commit is contained in:
@@ -30,17 +30,15 @@ type denebBlockGenerator struct {
|
||||
nblobs int
|
||||
sign bool
|
||||
sk bls.SecretKey
|
||||
pk bls.PublicKey
|
||||
proposer primitives.ValidatorIndex
|
||||
valRoot []byte
|
||||
}
|
||||
|
||||
func WithProposerSigning(idx primitives.ValidatorIndex, sk bls.SecretKey, pk bls.PublicKey, valRoot []byte) DenebBlockGeneratorOption {
|
||||
func WithProposerSigning(idx primitives.ValidatorIndex, sk bls.SecretKey, valRoot []byte) DenebBlockGeneratorOption {
|
||||
return func(g *denebBlockGenerator) {
|
||||
g.sign = true
|
||||
g.proposer = idx
|
||||
g.sk = sk
|
||||
g.pk = pk
|
||||
g.valRoot = valRoot
|
||||
}
|
||||
}
|
||||
@@ -97,6 +95,7 @@ func GenerateTestDenebBlockWithSidecar(t *testing.T, parent [32]byte, slot primi
|
||||
block.Block.Body.ExecutionPayload = payload
|
||||
block.Block.Slot = g.slot
|
||||
block.Block.ParentRoot = g.parent[:]
|
||||
block.Block.ProposerIndex = g.proposer
|
||||
commitments := make([][48]byte, g.nblobs)
|
||||
block.Block.Body.BlobKzgCommitments = make([][]byte, g.nblobs)
|
||||
for i := range commitments {
|
||||
|
||||
Reference in New Issue
Block a user