Commit fbbc56d
committed
feat(pyth-sui-js): migrate to @mysten/sui v2 API
Migrate @pythnetwork/pyth-sui-js, the Sui CLI tooling, and
contract_manager from @mysten/sui v1 to v2.
Key changes:
- Replace SuiClient with ClientWithCoreApi (transport-agnostic) in pyth-sui-js
- Use provider.core.* namespace for all data access methods
- BCS-encode dynamic field names as required by v2
- Update response handling for new object/json format
- Move @mysten/sui to peerDependencies (^2.0.0) in pyth-sui-js
- Update CLI to use SuiJsonRpcClient and fromBase64
- Migrate contract_manager to SuiJsonRpcClient for compatibility
- Update contract_manager tsconfig moduleResolution to bundler
- Narrow catch in getPriceFeedObjectId to only swallow not-found errors
- Bump pyth-sui-js version from 3.0.0 to 4.0.0
Closes #34541 parent 059f890 commit fbbc56d
10 files changed
Lines changed: 307 additions & 97 deletions
File tree
- contract_manager
- src/core
- target_chains/sui
- cli
- src
- sdk/js
- src
- examples
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
| 11 | + | |
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
17 | | - | |
| 16 | + | |
| 17 | + | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| |||
394 | 394 | | |
395 | 395 | | |
396 | 396 | | |
397 | | - | |
398 | | - | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
399 | 402 | | |
400 | 403 | | |
401 | 404 | | |
| |||
611 | 614 | | |
612 | 615 | | |
613 | 616 | | |
614 | | - | |
| 617 | + | |
615 | 618 | | |
616 | 619 | | |
617 | 620 | | |
| |||
658 | 661 | | |
659 | 662 | | |
660 | 663 | | |
661 | | - | |
| 664 | + | |
662 | 665 | | |
663 | 666 | | |
664 | 667 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
0 commit comments