refactor: import SVM utils from SDK instead of contracts (ACP-56)#3094
Draft
refactor: import SVM utils from SDK instead of contracts (ACP-56)#3094
Conversation
Update all SVM-related imports to use @across-protocol/sdk/svm instead of @across-protocol/contracts. This is part of the migration to move production Solana/SVM TypeScript utils from the contracts repo to the SDK. - SvmSpokeClient, TokenMessengerMinterClient, MessageTransmitterV2Client, TokenMessengerMinterV2Client, and IDLs now imported from sdk/svm - Deep path imports updated from contracts/dist/src/svm/ to sdk/dist/cjs/src/svm/ - Mixed imports split where SVM and non-SVM exports were combined Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Update @across-protocol/sdk to 4.4.0-alpha.1 which includes the migrated SVM utils. Use deep import paths (dist/cjs/src/svm) instead of subpath exports (sdk/svm) for compatibility with moduleResolution: "node". Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…al/acp-72-update-relayer-repo-usage
Switch to moduleResolution: "bundler" to support @across-protocol/sdk/svm subpath export. This is needed because the SDK's package.json exports field blocks direct dist/ path access with moduleResolution: "node". Also consolidate deep svm imports into top-level @across-protocol/sdk/svm. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The SDK imports @coral-xyz/borsh directly in its source files. When yarn loads SDK source during install/test, borsh must be hoisted to the top level. Adding it explicitly ensures hoisting. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Update all SVM-related imports to use @across-protocol/sdk/svm instead of @across-protocol/contracts. This is part of the migration to move production Solana/SVM TypeScript utils from the contracts repo to the SDK.