You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On a transfer on the transfers API the "amount" is the initial amount set up by the user.
I would expect that the same behaviour would be observed on governance initiated transfers but it is not.
Observed behaviour
On the governance transfer the below calculation is done.
transfer_amount = min(
proposal.fraction_of_balance * source.balance,
proposal.amount,
NETWORK_MAX_AMOUNT,
NETWORK_MAX_FRACTION * source.balance
)
where
NETWORK_MAX_AMOUNT is a network parameter specifying the maximum absolute amount that can be transferred by governance for the source account type
NETWORK_MAX_FRACTION is a network parameter specifying the maximum fraction of the balance that can be transferred by governance for the source account type (must be <= 1)
If type is "all or nothing" then the transfer will only proceed if:
transfer_amount == min(proposal.fraction_of_balance * source.balance,proposal.amount).
Expected behaviour
I would expect that both types of transfer are presented in exactly the same way ... however right now neither one is ideal to be honest.
The "amount" should be the initial amount set by the user when setting up the transfer or governance transfer so should be taken from the transfer transaction or the governance proposal directly
Steps to reproduce
1. Submit `xyz` transaction
4. With this payload
5. Query `abc` API
6. Observe the error
Software version
0.76
Failing test
No response
Jenkins run
No response
Configuration used
No response
Relevant log output
No response
The text was updated successfully, but these errors were encountered:
Problem encountered
On a transfer on the transfers API the "amount" is the initial amount set up by the user.
I would expect that the same behaviour would be observed on governance initiated transfers but it is not.
Observed behaviour
On the governance transfer the below calculation is done.
Expected behaviour
I would expect that both types of transfer are presented in exactly the same way ... however right now neither one is ideal to be honest.
Steps to reproduce
Software version
0.76
Failing test
No response
Jenkins run
No response
Configuration used
No response
Relevant log output
No response
The text was updated successfully, but these errors were encountered: