-
Notifications
You must be signed in to change notification settings - Fork 18
feat(epic): add SVM client #985
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
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: james-a-morris <[email protected]>
SVM events emit addresses with base58-encoding. At least two addresses emitted within an FundsDeposited or FilledRelay event will need to be converted to a base16 EVM address. Make it easy by permitting the caller of EvmAddress.from() to specify the encoding, defaulting to base16.
No functional change; only relocate so that all svm functionality is localised to src/arch/svm.
…slots (#973) Signed-off-by: james-a-morris <[email protected]>
Signed-off-by: bennett <[email protected]>
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.
Pull Request Overview
This PR implements a new SVM client along with several supporting refactors and improvements to address parsing and event handling across the codebase. Key changes include:
- Enhancements to AddressUtils to support both base16 and base58 encoded addresses for EVM and SVM.
- Addition of the SVM Spoke Pool client and associated event processing logic.
- Removal of deprecated SVM helper files and reorganization of the SVM-related modules.
Reviewed Changes
Copilot reviewed 12 out of 12 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
test/AddressUtils.ts | Reorganized imports and added thorough tests for both base58 and base16 encoded addresses. |
src/utils/AddressUtils.ts | Updated the Address classes to support an explicit encoding parameter for address decoding. |
src/svm/* | Removed redundant exports and helpers; refactored SVM module structure. |
src/clients/SpokePoolClient/SVMSpokePoolClient.ts | Introduced a new SVM-specific SpokePool client with methods for event querying and state updates. |
src/arch/svm/* | Added and modified SVM utility, types, and events client to support the new client and event processing. |
src/arch/svm/SpokeUtils.ts | Added basic implementations for SVM Spoke utilities with placeholders for unimplemented functions. |
_lowBlockNumber: number, | ||
_highBlockNumber?: number | ||
): Promise<number | undefined> { | ||
throw new Error("fillStatusArray: not implemented"); |
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.
The function findFillBlock throws an error with the message 'fillStatusArray: not implemented' which appears to be a copy-paste error. Please update the error message to accurately reflect the function name, e.g., 'findFillBlock: not implemented'.
throw new Error("fillStatusArray: not implemented"); | |
throw new Error("findFillBlock: not implemented"); |
Copilot uses AI. Check for mistakes.
No description provided.