cosmos-sdk/x/bank/CHANGELOG.md
2024-12-19 07:32:49 +00:00

4.0 KiB

Changelog

[Unreleased]

v0.2.0-rc.1 - 2024-12-18

Features

  • #17569 Introduce a new message type, MsgBurn, to burn coins.
  • #20014 Support app wiring for SendRestrictionFn.

Improvements

  • #18636 SendCoinsFromModuleToAccount, SendCoinsFromModuleToModule, SendCoinsFromAccountToModule, DelegateCoinsFromAccountToModule, UndelegateCoinsFromModuleToAccount, MintCoins and BurnCoins methods now returns an error instead of panicking if any module accounts does not exist or unauthorized.
  • #20517 SendCoins now checks for SendRestrictions before instead of after deducting coins using subUnlockedCoins.
  • #20354 Reduce the number of ValidateDenom calls in bank.SendCoins.
  • #21976 Resolve a footgun by swapping send restrictions check in InputOutputCoins before coin deduction.

Bug Fixes

  • #21407 Fix handling of negative spendable balances.
    • The SpendableBalances query now correctly reports spendable balances when one or more denoms are negative (used to report all zeros). Also, this query now looks up only the balances for the requested page.
    • The SpendableCoins keeper method now returns the positive spendable balances even when one or more denoms have more locked than available (used to return an empty Coins).
    • The SpendableCoin keeper method now returns a zero coin if there's more locked than available (used to return a negative coin).
  • #22543 Fix DenomMetadata rpc allow value with slashes

API Breaking Changes

  • #19954 Removal of the Address.String() method and related changes:
    • Changed NewInput, NewOutput, NewQueryBalanceRequest, NewQueryAllBalancesRequest, NewQuerySpendableBalancesRequest to accept a string instead of an AccAddress.
    • Added an address codec as an argument to NewSendAuthorization.
    • Added an address codec as an argument to SanitizeGenesisBalances which also returns an error.
    • (simulation) RandomGenesisBalances also returns an error.
  • #17569 BurnCoins takes an address instead of a module name
  • #19477 appmodule.Environment is passed to bank NewKeeper
  • #19627 The genesis api has been updated to match appmodule.HasGenesis.
  • #19740 InitGenesis and ExportGenesis module code and keeper code do not panic but return errors.

Consensus Breaking Changes

  • #19188 Remove creation of BaseAccount when sending a message to an account that does not exist