Skip to content

authtx doesn't support configuring aminojson encoder #25221

@mhofman

Description

@mhofman

While switching to 0.50 we realized we need to configure custom fields encoders in our app to avoid breaking changes in amino json sign mode.

However it is not currently possible to access the encoder created by NewTxConfig / NewTxConfigWithOptions, requiring us to duplicate the SDK's logic to create the TxConfig.

I see 2 possible approaches:

  • Accept an AminoEncoder in configOpts. The problem with that approach is that the EncoderOptions share some resolvers derived from the signing options that are normally just created by default. So specifying an explicit encoder would require the user to still duplicate some default options handling logic from the SDK, risking getting out of sync when things change.
  • Expose the AminoEncoder from the returned TxConfig / HandlerMap

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions