Closed taariq closed 1 year ago
@webelf101 please revert the added logs so we can explore a new approach next week.
@alexanderbez re-opening for your reiew.
Ok, seems like the panic is triggered from the log line added in x/consensus/keeper/attest.go
.
@taariq do you have the entire stacktrace? Is it a nil deference error? I can't tell what's going on from the given stacktrace. However, I'm pretty confident it's due to msg.String()
-- something funky is going on with that.
Instead, consider the following git diff change:
diff --git a/x/consensus/keeper/attest.go b/x/consensus/keeper/attest.go
index 7d27ad0..c386b03 100644
--- a/x/consensus/keeper/attest.go
+++ b/x/consensus/keeper/attest.go
@@ -1,6 +1,8 @@
package keeper
import (
+ "fmt"
+
sdk "github.com/cosmos/cosmos-sdk/types"
)
@@ -20,11 +22,18 @@ func (k Keeper) CheckAndProcessAttestedMessages(ctx sdk.Context) error {
}
for _, msg := range msgs {
- k.Logger(ctx).Info("check-and-process-attested-messages-queue", "id", msg.GetId(), "nonce", msg.Nonce(), "string", msg.String())
+ k.Logger(ctx).Info(
+ "check-and-process-attested-messages-queue",
+ "id", msg.GetId(),
+ "nonce", msg.Nonce(),
+ "string", fmt.Sprintf("+%v", msg),
+ )
+
cq, err := k.getConsensusQueue(ctx, opt.QueueTypeName)
if err != nil {
return err
}
+
if err := opt.ProcessMessageForAttestation(ctx, cq, msg); err != nil {
return err
}
Fixed with #613
What is happening?
Section description
Provide as much context as you can. Give as much context as you can to make it easier for the developers to figure what is happening.Added logs from https://github.com/palomachain/paloma/pull/610 to track attestation failures. Now getting consensus panic.