-
Notifications
You must be signed in to change notification settings - Fork 176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[node] Add more info on error logs #187
Conversation
b5ef5bc
to
5c9d218
Compare
@@ -10,7 +10,6 @@ import ( | |||
|
|||
var ( | |||
ErrChunkLengthMismatch = errors.New("chunk length mismatch") | |||
ErrInvalidHeader = errors.New("invalid header") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not being used
@@ -9,7 +9,6 @@ import ( | |||
|
|||
var ( | |||
ErrChunkLengthMismatch = errors.New("chunk length mismatch") | |||
ErrInvalidHeader = errors.New("invalid header") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not being used
@@ -28,7 +29,11 @@ var ( | |||
|
|||
// Assignment | |||
|
|||
type OperatorID = [32]byte |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
type aliases are convenient, but I think strict types are safer in general (and allow receiver functions)
@@ -114,7 +114,7 @@ func (f *operatorSocketsFilterer) WatchOperatorSocketUpdate(ctx context.Context, | |||
} | |||
|
|||
sink := make(chan *blsregcoord.ContractBLSRegistryCoordinatorWithIndicesOperatorSocketUpdate) | |||
operatorID := []core.OperatorID{operatorId} | |||
operatorID := [][32]byte{operatorId} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this intended given the goal of this pr?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah this is a consequence of making core.OperatorID
an explicit type - contract bindings aren't aware of core.OperatorID
, so needs to be converted to a primitive type
Why are these changes needed?
core.OperatorID
and explicit type instead of an alias, and added a helper method to convert to hex stringChecks