Open GitBolt opened 2 years ago
I wasn't able to find documentation which covers the code in calc-tx-cost.en.ts and it's preview. Hence, I haven't added anything to the documentation for it's Python equivalent example.
@jacobcreech I've added the Python equivalent example for calc-tx-cost.en.ts, however in basic-transactions.md
, it seems like there is no place where it's being used. calc-tx-est-fees-for-message.en
and calc-tx-est-fees.en.ts
are being used however calc-tx-cost.en.ts
isn't there, so I'm a little unsure where I'm supposed to add the Python example.
You could just add a component for SolanaCodeGroupItem
in the list like everywhere else that has the type python
@jacobcreech Done! Please review
Hey @GitBolt, that python example is actually not the same as the Typescript example. Not only that, but it will be out of date soon as fees change.
Make sure you use the getFeeForMessage
RPC API call with the Transaction Message to get an accurate fee calculation. You can update with the python example and set it here
@jacobcreech Yeah that's why I was confused since there was no example in the docs for the TypeScript equivalent as I asked earlier. About the out of date part, Solana.py hasn't implemented the getFeeForMessage
method yet, however I've built a library which does have it, is it okay if I use it? You can check it out here - Solathon
I'd probably contribute the new RPC call and then update. The current SDK is very open to contributions
The latest updates on your projects. Learn more about Vercel for Git ↗︎