Skip to content

[bug]: need to enforce common decimal_display across all minted traunches of a grouped asset when validating proofs #1503

Open
@ZZiigguurraatt

Description

@ZZiigguurraatt

When minting additional traunches of a grouped asset, we have the freedom to define different metadata when minting each traunch.

decimal_display is stored in the asset metadata. Right now when minting, we have a simple check to see if the same decimal_display used for additional traunches is the same as the first traunch:

https://github.com/lightninglabs/taproot-assets/blob/main/tapgarden/seedling.go#L201-L225

However, this isn't really enforced on the client side right now when validating proofs. Therefor, a node minting assets could remove the check above and mint a second traunch with a different decimal_display and then the nodes using the taproot assets from multiple traunches won't really notice and then there could be confusion in the marketplace because different people are assuming different decimal_display values for the asset.

We need to enforce this client side when validating proofs for an asset. Although there might be uses cases for different metadata for different traunches (which is why we have the freedom to change it), decimal_display is one use case in the metadata that it doesn't make sense for it to be able to change from one traunch to another traunch.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions