Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Balances::transfer will be removed #9854

Closed
ggwpez opened this issue Sep 6, 2023 · 4 comments
Closed

Balances::transfer will be removed #9854

ggwpez opened this issue Sep 6, 2023 · 4 comments

Comments

@ggwpez
Copy link

ggwpez commented Sep 6, 2023

Just a heads-up that there will be a breaking change to the balances pallet here: paritytech/polkadot-sdk#1226

Two calls will be renamed removed:

  • transfer -> transfer_allow_death
  • set_balance_deprecated -> force_set_balance

Feel free to close if this will be handled automatically, just wanted to ensure that you are not surprised by it 😄

cc @juangirini

@juangirini
Copy link
Contributor

Not sure if this affects the front end, but just in case, they are not actually renamed, they are removed (which means that their indexes are not longer valid), and the other functions should be used instead.
This comes from the Currency deprecation PR paritytech/substrate#12951

@jacogr
Copy link
Member

jacogr commented Sep 6, 2023

It has been handled for a while,

tx={
canToggleAll && isAll && isFunction(api.tx.balances?.transferAll)
? api.tx.balances?.transferAll
: isProtected
? api.tx.balances?.transferKeepAlive
: api.tx.balances?.transferAllowDeath || api.tx.balances?.transfer
}

(After this PR when the new extrinsics went in around 6-odd months ago - #9221 it will always default to the newest with a fallback for older chains)

@jacogr jacogr closed this as completed Sep 6, 2023
@juangirini
Copy link
Contributor

@jacogr just to triple check, do set_balance_deprecated -> force_set_balance follow the same fashion?

@polkadot-js-bot
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue if you think you have a related problem or query.

@polkadot-js polkadot-js locked as resolved and limited conversation to collaborators Sep 13, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants