Skip to content
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

oracle package #33

Open
wants to merge 2 commits into
base: devel
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
oracle package
0xLendlord committed Oct 25, 2024
commit 2d56cd44ca846e9ee4cc0d5a03221a37771a0a2d
44 changes: 44 additions & 0 deletions Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "299C528AE40C90988AEFDCD4CE6592954C94F04CB5F7C7632FA0A91E21E0275B"
deps_digest = "3C4103934B1E040BB6B23F1D610B4EF9F2F1166A50A104EADCF77467C004C600"
dependencies = [
{ id = "Pyth", name = "Pyth" },
{ id = "Sui", name = "Sui" },
]

[[move.package]]
id = "MoveStdlib"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/mainnet", subdir = "crates/sui-framework/packages/move-stdlib" }

[[move.package]]
id = "Pyth"
source = { git = "https://github.com/solendprotocol/pyth-crosschain.git", rev = "98e218c64bb75cf1350eb7b021e1ffcc3aedfd62", subdir = "target_chains/sui/contracts" }

dependencies = [
{ id = "Sui", name = "Sui" },
{ id = "Wormhole", name = "Wormhole" },
]

[[move.package]]
id = "Sui"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/mainnet", subdir = "crates/sui-framework/packages/sui-framework" }

dependencies = [
{ id = "MoveStdlib", name = "MoveStdlib" },
]

[[move.package]]
id = "Wormhole"
source = { git = "https://github.com/solendprotocol/wormhole.git", rev = "e1698d3c72b15cdddd7da98ad43e151f83b72a0a", subdir = "sui/wormhole" }

dependencies = [
{ id = "Sui", name = "Sui" },
]

[move.toolchain-version]
compiler-version = "1.36.1"
edition = "2024.beta"
flavor = "sui"
44 changes: 44 additions & 0 deletions contracts/oracle/Move.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 3
manifest_digest = "06DF582C04BE62FC78290C20A1F78ED655FCB9A6F1680B3B605F4D1627713DF4"
deps_digest = "3C4103934B1E040BB6B23F1D610B4EF9F2F1166A50A104EADCF77467C004C600"
dependencies = [
{ id = "Pyth", name = "Pyth" },
{ id = "Sui", name = "Sui" },
]

[[move.package]]
id = "MoveStdlib"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/mainnet", subdir = "crates/sui-framework/packages/move-stdlib" }

[[move.package]]
id = "Pyth"
source = { git = "https://github.com/solendprotocol/pyth-crosschain.git", rev = "98e218c64bb75cf1350eb7b021e1ffcc3aedfd62", subdir = "target_chains/sui/contracts" }

dependencies = [
{ id = "Sui", name = "Sui" },
{ id = "Wormhole", name = "Wormhole" },
]

[[move.package]]
id = "Sui"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/mainnet", subdir = "crates/sui-framework/packages/sui-framework" }

dependencies = [
{ id = "MoveStdlib", name = "MoveStdlib" },
]

[[move.package]]
id = "Wormhole"
source = { git = "https://github.com/solendprotocol/wormhole.git", rev = "e1698d3c72b15cdddd7da98ad43e151f83b72a0a", subdir = "sui/wormhole" }

dependencies = [
{ id = "Sui", name = "Sui" },
]

[move.toolchain-version]
compiler-version = "1.36.1"
edition = "2024.beta"
flavor = "sui"
17 changes: 17 additions & 0 deletions contracts/oracle/Move.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
[package]
name = "Oracle"
version = "0.0.1"
published-at = "0x0"
edition="2024.beta"

[dependencies]
Sui = { git = "https://github.com/MystenLabs/sui.git", subdir = "crates/sui-framework/packages/sui-framework", rev = "framework/mainnet", override = true }

[dependencies.Pyth]
git = "https://github.com/solendprotocol/pyth-crosschain.git"
subdir = "target_chains/sui/contracts"
rev = "98e218c64bb75cf1350eb7b021e1ffcc3aedfd62"

[addresses]
oracle = "0xff"
pyth = "0x8d97f1cd6ac663735be08d1d2b6d02a159e711586461306ce60a2b7a6a565a9e"
486 changes: 486 additions & 0 deletions contracts/oracle/sources/oracle_wrapper.move

Large diffs are not rendered by default.

656 changes: 656 additions & 0 deletions contracts/oracle/sources/pyth.move

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions contracts/suilend/Move.beta.toml
Original file line number Diff line number Diff line change
@@ -15,6 +15,8 @@ git = "https://github.com/solendprotocol/pyth-crosschain.git"
subdir = "target_chains/sui/contracts"
rev = "98e218c64bb75cf1350eb7b021e1ffcc3aedfd62"

Oracle = { local="../oracle" }

[addresses]
sui = "0x2"
suilend = "0xba79417dd36e8fa1510f53b0491b7a8b2802217a81b1401b1efbb65e4994e016"
35 changes: 22 additions & 13 deletions contracts/suilend/Move.lock
Original file line number Diff line number Diff line change
@@ -1,44 +1,53 @@
# @generated by Move, please check-in and do not edit manually.

[move]
version = 2
manifest_digest = "97E92C3AE2671D15B98EDF2F75D00F01F060C660AA87BCA5FB95A6792D62C242"
version = 3
manifest_digest = "299C528AE40C90988AEFDCD4CE6592954C94F04CB5F7C7632FA0A91E21E0275B"
deps_digest = "3C4103934B1E040BB6B23F1D610B4EF9F2F1166A50A104EADCF77467C004C600"
dependencies = [
{ name = "Pyth" },
{ name = "Sui" },
{ id = "Oracle", name = "Oracle" },
{ id = "Pyth", name = "Pyth" },
{ id = "Sui", name = "Sui" },
]

[[move.package]]
name = "MoveStdlib"
id = "MoveStdlib"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/mainnet", subdir = "crates/sui-framework/packages/move-stdlib" }

[[move.package]]
name = "Pyth"
id = "Oracle"
source = { local = "../oracle" }

dependencies = [
{ id = "Sui", name = "Sui" },
]

[[move.package]]
id = "Pyth"
source = { git = "https://github.com/solendprotocol/pyth-crosschain.git", rev = "98e218c64bb75cf1350eb7b021e1ffcc3aedfd62", subdir = "target_chains/sui/contracts" }

dependencies = [
{ name = "Sui" },
{ name = "Wormhole" },
{ id = "Sui", name = "Sui" },
{ id = "Wormhole", name = "Wormhole" },
]

[[move.package]]
name = "Sui"
id = "Sui"
source = { git = "https://github.com/MystenLabs/sui.git", rev = "framework/mainnet", subdir = "crates/sui-framework/packages/sui-framework" }

dependencies = [
{ name = "MoveStdlib" },
{ id = "MoveStdlib", name = "MoveStdlib" },
]

[[move.package]]
name = "Wormhole"
id = "Wormhole"
source = { git = "https://github.com/solendprotocol/wormhole.git", rev = "e1698d3c72b15cdddd7da98ad43e151f83b72a0a", subdir = "sui/wormhole" }

dependencies = [
{ name = "Sui" },
{ id = "Sui", name = "Sui" },
]

[move.toolchain-version]
compiler-version = "1.34.1"
compiler-version = "1.36.1"
edition = "2024.beta"
flavor = "sui"
2 changes: 2 additions & 0 deletions contracts/suilend/Move.mainnet.toml
Original file line number Diff line number Diff line change
@@ -15,6 +15,8 @@ git = "https://github.com/solendprotocol/pyth-crosschain.git"
subdir = "target_chains/sui/contracts"
rev = "98e218c64bb75cf1350eb7b021e1ffcc3aedfd62"

Oracle = { local="../oracle" }

[addresses]
sui = "0x2"
# suilend = "0x0"
2 changes: 2 additions & 0 deletions contracts/suilend/Move.toml
Original file line number Diff line number Diff line change
@@ -15,6 +15,8 @@ git = "https://github.com/solendprotocol/pyth-crosschain.git"
subdir = "target_chains/sui/contracts"
rev = "98e218c64bb75cf1350eb7b021e1ffcc3aedfd62"

Oracle = { local="../oracle" }

[addresses]
sui = "0x2"
# suilend = "0x0"