Cannot run sol-contract example
Closed this issue · 4 comments
- cd examples/sol-contract
- cargo build
error
no method named
get_current_pricefound for struct
PriceFeedin the current scope
examples/sol-contract/src/processor.rs:87:33
let result1 = feed1.get_current_price().ok_or(ProgramError::Custom(3))?;
If I rollback to commit 'An example contract for solana (#72)' I can go one step further:
- cd examples/sol-contract
- cargo build
- cd scripts
- sh build.sh
error
error: failed to select a version for the requirement time = "^0.3"
candidate versions found which didn't match: 0.3.15, 0.3.14, 0.3.13,
Thanks for reporting the issue and sorry for the confusion. We recently updated the Pyth SDK interface causing this issue. I have created a related PR and I expect to have the issue fixed soon, after the PR is merged.
@yhzhang0128 tried your branch 'adapt-api', still getting error 'failed to select a version for the requirement time = "^0.3"
' on 'sh build.sh'
Hi @5elfle5, can you please update your solana cli tools to the latest version? This solves the issue you are facing now. (#85 describes more).
Please reopen the issue if you are facing any other problems.