|
|
3 viikkoa sitten | |
|---|---|---|
| .. | ||
| pyth-contract | 9f26ac575d fixed test | 3 kuukautta sitten |
| pyth-interface | c3e0f491e4 explaining byte padding | 3 kuukautta sitten |
| scripts | 6b1c016619 quick simplification | 3 kuukautta sitten |
| src | 955a805e85 chore: apply rustfmt | 1 vuosi sitten |
| tests | 955a805e85 chore: apply rustfmt | 1 vuosi sitten |
| .gitignore | ab0cf6f7d8 chore: updated gitignore to excluse the built dist/ folder | 3 viikkoa sitten |
| Cargo.lock | 04906de2e1 checking whether this works | 4 kuukautta sitten |
| Cargo.toml | f04cae050f feat(target_chains/fuel): update fuel toolchains to the latest version (#1911) | 1 vuosi sitten |
| Forc.lock | 04906de2e1 checking whether this works | 4 kuukautta sitten |
| Forc.toml | c2da454637 add fuel contract by Fuel Labs (#1513) | 1 vuosi sitten |
| LICENSE | c2da454637 add fuel contract by Fuel Labs (#1513) | 1 vuosi sitten |
| README.md | 7de4ce3ec8 update fuel readme (#2052) | 1 vuosi sitten |
| fuel-toolchain.toml | 7d74c6f002 only made changes to the fuel folder | 3 kuukautta sitten |
An implementation of a Pyth Network oracle contract in Sway. Utilising minimal, internal Wormhole functionality and state.
The project provides four interfaces for interaction with the oracle contract:
Run the following commands from the root of the repository.
forc build
Before running the tests the programs must be compiled with the command above.
cargo test
Before deploying the oracle contract; the deployer must be set to the address of the deploying wallet in the storage block, so that the deployer can setup the contract with the constructor() method.
Parameters for the constructor() method can be seen in the tests of the method, which at the time of writing uses the real up-to-date values as per Pyth's documentation and EVM integrations. Care should be taken to ensure that the most up-to-date values are used for the constructor() method's parameters.
The Pyth oracle contract has been deployed to Mainnet at 0x1c86fdd9e0e7bc0d2ae1bf6817ef4834ffa7247655701ee1b031b52a24c523da and Testnet at 0x25146735b29d4216639f7f8b1d7b921ff87a1d3051de62d6cceaacabeb33b8e7.