* v1.2.10

* v1.2.10
This commit is contained in:
Cassandra Heart 2024-02-20 01:59:03 -06:00 committed by GitHub
parent f8726882de
commit ab700df594
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
7 changed files with 37 additions and 26 deletions

View File

@ -886,11 +886,11 @@ func logoVersion(width int) string {
out += " ####################################### ########\n"
out += " ############################# ##\n"
out += " \n"
out += " Quilibrium Node - v1.2.9 Dawn\n"
out += " Quilibrium Node - v1.2.10 Dawn\n"
out += " \n"
out += " DB Console\n"
} else {
out = "Quilibrium Node - v1.2.9 Dawn - DB Console\n"
out = "Quilibrium Node - v1.2.10 Dawn - DB Console\n"
}
return out
}

View File

@ -128,10 +128,6 @@ func (e *CeremonyDataClockConsensusEngine) handleCeremonyPeerListAnnounce(
address []byte,
any *anypb.Any,
) error {
if bytes.Equal(peerID, e.pubSub.GetPeerID()) {
return nil
}
announce := &protobufs.CeremonyPeerListAnnounce{}
if err := any.UnmarshalTo(announce); err != nil {
return errors.Wrap(err, "handle ceremony peer list announce")
@ -284,10 +280,6 @@ func (e *CeremonyDataClockConsensusEngine) handleClockFrameData(
any *anypb.Any,
isSync bool,
) error {
if isSync && bytes.Equal(peerID, e.pubSub.GetPeerID()) {
return nil
}
frame := &protobufs.ClockFrame{}
if err := any.UnmarshalTo(frame); err != nil {
return errors.Wrap(err, "handle clock frame data")

View File

@ -151,6 +151,13 @@ func (e *CeremonyDataClockConsensusEngine) GetMostAheadPeer() (
panic(err)
}
e.logger.Info(
"checking peer list",
zap.Int("peers", len(e.peerMap)),
zap.Int("uncooperative_peers", len(e.uncooperativePeersMap)),
zap.Uint64("current_head_frame", frame.FrameNumber),
)
max := frame.FrameNumber
var peer []byte = nil
for _, v := range e.peerMap {

View File

@ -72,7 +72,7 @@ func (e *CeremonyDataClockConsensusEngine) GetCompressedSyncFrames(
if parent != nil {
if !bytes.Equal(frame.ParentSelector, parent) {
e.logger.Info(
e.logger.Debug(
"peer specified out of consensus head, seeking backwards for fork",
)
}
@ -95,7 +95,11 @@ func (e *CeremonyDataClockConsensusEngine) GetCompressedSyncFrames(
parent,
)
if err != nil {
from = frame.FrameNumber - 16
if frame.FrameNumber > 18 {
from = frame.FrameNumber - 16
} else {
from = 2
}
e.logger.Debug("peer fully out of sync, rewinding sync head to min")
break
}
@ -121,9 +125,9 @@ func (e *CeremonyDataClockConsensusEngine) GetCompressedSyncFrames(
}
for {
if to == 0 || to-from > 32 {
if max > from+31 {
to = from + 32
if to == 0 || to-from > 16 {
if max > from+15 {
to = from + 16
} else {
to = max + 1
}

View File

@ -51,13 +51,13 @@ type DataConsensusEngine interface {
}
func GetMinimumVersionCutoff() time.Time {
return time.Date(2024, time.February, 19, 0, 0, 0, 0, time.UTC)
return time.Date(2024, time.February, 20, 7, 0, 0, 0, time.UTC)
}
func GetMinimumVersion() []byte {
return []byte{0x01, 0x02, 0x09}
return []byte{0x01, 0x02, 0x0A}
}
func GetVersion() []byte {
return []byte{0x01, 0x02, 0x09}
return []byte{0x01, 0x02, 0x0A}
}

View File

@ -62,6 +62,8 @@ type CeremonyExecutionEngine struct {
frameProver qcrypto.FrameProver
}
const validCeremonySelector = "253f3a6383dcfe91cf49abd20204b3e6ef5afd4c70c1968bb1f0b827a72af53b"
func NewCeremonyExecutionEngine(
logger *zap.Logger,
engineConfig *config.EngineConfig,
@ -93,16 +95,22 @@ func NewCeremonyExecutionEngine(
var proverKeys [][]byte
rebuildGenesisFrame := false
if frame != nil &&
len(frame.AggregateProofs[0].InclusionCommitments[0].Data) < 2000 {
logger.Warn("corrupted genesis frame detected, rebuilding")
err = clockStore.ResetDataClockFrames(intrinsicFilter)
if frame != nil {
selector, err := frame.GetSelector()
if err != nil {
panic(err)
}
rebuildGenesisFrame = true
if selector.Text(16) != validCeremonySelector {
logger.Warn("corrupted genesis frame detected, rebuilding")
err = clockStore.ResetDataClockFrames(intrinsicFilter)
if err != nil {
panic(err)
}
rebuildGenesisFrame = true
}
}
if err != nil && errors.Is(err, store.ErrNotFound) || rebuildGenesisFrame {

View File

@ -66,7 +66,7 @@ func main() {
if *memprofile != "" {
go func() {
for {
time.Sleep(20 * time.Minute)
time.Sleep(5 * time.Minute)
f, err := os.Create(*memprofile)
if err != nil {
log.Fatal(err)
@ -306,5 +306,5 @@ func printLogo() {
func printVersion() {
fmt.Println(" ")
fmt.Println(" Quilibrium Node - v1.2.9 Dawn")
fmt.Println(" Quilibrium Node - v1.2.10 Dawn")
}