Replies - Activity - plasmatech8 - Algorand
Cannot calculate suggested fees for inner transactions
Another thing, I do not think it is possible to calculate the num_bytes for inner transactions. (need to look into dryruns) That may complicate things a little bit since you need to pay for the bytes of inner transactions too. And there is no way to get it easily/conveniently.
I have made an gh issue and I think it clarified a few things for me as well. The fee parameter (fee-per-byte) returned by the API is indeed correct (it is zero until network congestion occurs). The fee-per-byte is NOT a problem.
Is this a bug?
As stated above, suggested_params.min_fee has no effect...
Actually, there might be a way to get the exact total fee for a transaction using dryruns. You would need to construct and sign the transaction twice though.
suggested_params.fee = suggested_params.min_fee * 2 suggested_params.flat_fee = True
Looks good. I did not know about the flat fee. I can see that if flat_fee = True, then fee is the total fee instead of the fee per byte (as I can see in py algosdk docs for the SuggestedParams).
Thanks for the reply. 🙂
The simplest solution for that is to set: suggested_params.min_fee = suggested_params.min_fee * 2 I have been trying this, but the min_fee has no effect on whether the transaction is accepted or rejected. For example, I have tried:
Delete Application Txn which contain...
I think I might be confusing myself a bit. The real question might be: How do I get suggested fee per byte, and why does the API return fee-per-byte of 0?