diff --git a/synchronizer/synchronizer.go b/synchronizer/synchronizer.go index 3f7b2bb..077ee35 100644 --- a/synchronizer/synchronizer.go +++ b/synchronizer/synchronizer.go @@ -1080,7 +1080,7 @@ func (s *Synchronizer) auctionSync(ethBlock *common.Block) (*common.AuctionData, } s.vars.Auction.DefaultSlotSetBid[evt.SlotSet] = evt.NewInitialMinBid s.vars.Auction.DefaultSlotSetBidSlotNum = s.consts.Auction.SlotNum(blockNum) + - int64(s.vars.Auction.ClosedAuctionSlots) + 1 + int64(s.vars.Auction.ClosedAuctionSlots) varsUpdate = true } diff --git a/test/ethclient.go b/test/ethclient.go index b6185e8..bc8ee83 100644 --- a/test/ethclient.go +++ b/test/ethclient.go @@ -1429,11 +1429,11 @@ func (c *Client) AuctionBid(amount *big.Int, slot int64, bidAmount *big.Int, nextBlock := c.nextBlock() a := nextBlock.Auction - if slot < a.getCurrentSlotNumber()+int64(a.Vars.ClosedAuctionSlots) { + if slot <= a.getCurrentSlotNumber()+int64(a.Vars.ClosedAuctionSlots) { return nil, tracerr.Wrap(errBidClosed) } - if slot >= a.getCurrentSlotNumber()+int64(a.Vars.ClosedAuctionSlots)+int64(a.Vars.OpenAuctionSlots) { + if slot > a.getCurrentSlotNumber()+int64(a.Vars.ClosedAuctionSlots)+int64(a.Vars.OpenAuctionSlots) { return nil, tracerr.Wrap(errBidNotOpen) }