-
Notifications
You must be signed in to change notification settings - Fork 19
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
C-Chain compatibility #115
Conversation
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.
.
relayer/message_relayer.go
Outdated
return nil, err | ||
} | ||
return warpMsg, err | ||
} else { |
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.
don't think we need this else
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.
Good call. Removed.
@@ -311,7 +411,7 @@ func (r *messageRelayer) createSignedMessage(requestID uint32) (*warp.Message, e | |||
} | |||
|
|||
// As soon as the signatures exceed the stake weight threshold we try to aggregate and send the transaction. | |||
if utils.CheckStakeWeightExceedsThreshold(accumulatedSignatureWeight, totalValidatorWeight, utils.DefaultQuorumNumerator, utils.DefaultQuorumDenominator) { | |||
if utils.CheckStakeWeightExceedsThreshold(accumulatedSignatureWeight, totalValidatorWeight, params.WarpDefaultQuorumNumerator, params.WarpQuorumDenominator) { |
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.
should we by default be using the coreth.params
? What if subnet-evm
has different values, and the message we're sending doesn't interact with the primary network
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, we should make that distinction. I added a comment to #8 to fetch the numerator config from the VM, rather than using a hardcoded value.
d12a01d
Why this should be merged
With Avalanchego v1.10.17, Warp is enabled by default on the C-Chain for local networks, opening a path to easily test Teleporter and AWM Relayer. This PR adds E2E test cases to test relaying between the C-Chain and a subnet, as well as modifications to the relayer signature aggregation logic.
Fixes #113
Fixes #117
How this works
Modifies the internal signature aggregation logic to use the Warp client included insubnet-evm
andcoreth
, rather than the custom AppRequest logic. There are further changes needed to get the AppRequest approach working with the C-Chain, meanwhile the Warp client works out-of-the-box (issue here: Support AppRequests for the C-Chain #117)How this was tested
Extended E2E tests.
How is this documented
N/A