miner code needs to pass all tickets to create block
This commit is contained in:
parent
08b6d34adc
commit
75b343a54a
@ -198,7 +198,7 @@ func (m *Miner) mineOne(ctx context.Context, base *MiningBase) (*chain.BlockMsg,
|
|||||||
return nil, errors.Wrap(err, "scratching ticket failed")
|
return nil, errors.Wrap(err, "scratching ticket failed")
|
||||||
}
|
}
|
||||||
|
|
||||||
win, proof, err := gen.IsRoundWinner(ctx, base.ts, base.tickets, m.addresses[0], &m.api)
|
win, proof, err := gen.IsRoundWinner(ctx, base.ts, append(base.tickets, ticket), m.addresses[0], &m.api)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, errors.Wrap(err, "failed to check if we win next round")
|
return nil, errors.Wrap(err, "failed to check if we win next round")
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user