Skip to content

Conversation

@cctdaniel
Copy link
Contributor

@cctdaniel cctdaniel commented Feb 29, 2024

I upgraded @pythnetwork/client to the latest version to support maxLatency however, in the latest js package, its using "@coral-xyz/anchor": "^0.28.1-beta.1" and so there were errors resulting from the packages having inconsistent versions and therefor I upgraded the versions in the relevant packages to be consistent

@vercel
Copy link

vercel bot commented Feb 29, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
xc-admin-frontend ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 4, 2024 7:08am
1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
example-oracle-amm ⬜️ Ignored (Inspect) Visit Preview Mar 4, 2024 7:08am

},
"dependencies": {
"@coral-xyz/anchor": "^0.26.0",
"@coral-xyz/anchor": "^0.28.1-beta.1",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this has to be the same as the version of @coral-xyz/anchor that @pythnetwork/client is using

const provider = new AnchorProvider(
connection,
squads.wallet,
squads.wallet as Wallet,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

upgraded @coral-xyz/anchor version and now AnchorProvider requires a slightly different Wallet interface but squads.wallet is still using an old version of @projectserum/anchor package

setData(sortDataMemo(symbolToData))
}
}, [rawConfig, dataIsLoading, sortDataMemo])
}, [rawConfig, dataIsLoading, sortDataMemo, cluster])
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

missing dependency cluster since it is being used in the useEffect hook

Copy link
Contributor

@guibescos guibescos Feb 29, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mmmm I'm not sure about this, maybe it's fine because changing cluster updates some of the other deps

"url": "git+https://github.com/pyth-network/pyth-crosschain.git"
},
"dependencies": {
"@coral-xyz/anchor": "^0.28.1-beta.1",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this package was using @coral-xyz/anchor but didnt pin the version here hence it was using an old version of the package that some other packages are using, generally I think its a good idea to pin versions specific to packages

const programAuthorityEscrowIdl = await Program.fetchIdl(
PROGRAM_AUTHORITY_ESCROW,
vault.getAnchorProvider()
vault.getAnchorProvider() as AnchorProvider
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These casts are not needed

Copy link
Contributor

@guibescos guibescos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please check the comments

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants