ameliatastic / seahorse-lang

Write Anchor-compatible Solana programs in Python
Apache License 2.0
320 stars 46 forks source link

Pyth integration #48

Closed ameliatastic closed 1 year ago

ameliatastic commented 1 year ago

Adding Pyth integration, partially because I wanted to see it happen and partially because it was easy enough that my commits here can be used as a tutorial for anyone that wants to add another Seahorse module (whether it's for an external program or otherwise).

The first 3 commits add a working (at least, it compiles lol) + minimal support for Pyth price feeds. I wrote everything at the same time but split the actual push into 3 separate commits for readability:

Hope this helps!

Closes #46

mcintyre94 commented 1 year ago

This is awesome! The only concern I'd have is how much of an impact it has on deploy cost for projects not using Pyth. I'm not really sure I have a good understanding of the implications of it being included by default.