After #2939, the TX executor assumes the callback flag of the fee asset is set to disabled and the composition of the asset is AssetComposition::Fungible. Since users only provide the fee faucet ID when constructing FeeParameters, this set of requirements is never explicitly checked, which is error-prone. Users could be providing the account ID of a faucet that issues non-fungible, callback-enabled assets, and so the fee asset essentially does not exist in practice.
Consider changing FeeParameters::fee_faucet_id to a fee_asset_key: AssetVaultKey and checking the above requirements in the constructor instead, to provide feedback to the caller.
The tx kernel should likely also take the whole asset key as an input (provided as advice) rather than just the faucet ID, which is less error-prone.
Brought up by @mmagician in #2939 (comment).
After #2939, the TX executor assumes the callback flag of the fee asset is set to disabled and the composition of the asset is
AssetComposition::Fungible. Since users only provide the fee faucet ID when constructingFeeParameters, this set of requirements is never explicitly checked, which is error-prone. Users could be providing the account ID of a faucet that issues non-fungible, callback-enabled assets, and so the fee asset essentially does not exist in practice.Consider changing
FeeParameters::fee_faucet_idto afee_asset_key: AssetVaultKeyand checking the above requirements in the constructor instead, to provide feedback to the caller.The tx kernel should likely also take the whole asset key as an input (provided as advice) rather than just the faucet ID, which is less error-prone.
Brought up by @mmagician in #2939 (comment).