Replies: 1 comment 2 replies
-
|
If this is removed, it would be great to see a replacement added to the specification that allows for some fee control (instead of just using metadata JSON, as many assets do now). |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Deprecate two fields in the ConstructionPreprocessRequest endpoint
The ConstructionPreprocessRequest endpoint includes the
max_feeandsuggested_fee_multiplierfields, which are optional. Coinbase is looking to remove these fields from the ConstructionPreprocessRequest endpoint.Why we want to remove it
In our current workflow, we configure these two fields ourselves, instead of using values from Rosetta. As a result, these two fields add unnecessary complexity for Asset Issuers (AIs) and Coinbase.
Situation 1: AIs provide a
max_feethat is lower than the current network fee. Rosetta may refuse the transactions, or the transactions will take a long time to be confirmed. This issue adds complexity.Situation 2: In order to pass the
check:constructiontest, AIs may give thesuggested_fee_multipliervalue a high number. This will make our TXs fee unnecessary higher, which may lead to money loss for both Coinbase and users.Benefits
By removing these two fields, our metadata's
suggested_feevalue will be more reliable.This will help Coinbase and its users pay appropriate fees for their TXs.
Potential risks
Some AIs are using these fields
Solution:
max_feeandsuggested_fee_multiplierfields from ConstructionPreprocessRequest.After updating the spec, the
ConstructionPreprocessRequestwill look like :{ "network_identifier": { "blockchain": "bitcoin", "network": "mainnet", "sub_network_identifier": { "network": "shard 1", "metadata": { "producer": "0x52bc44d5378309ee2abf1539bf71de1b7d7be3b5" } } }, "operations": [ { "operation_identifier": { "index": 5, "network_index": 0 }, "related_operations": [ { "index": 1 }, { "index": 2 } ], "type": "Transfer", "status": "Reverted", "account": { "address": "0x3a065000ab4183c6bf581dc1e55a605455fc6d61", "sub_account": { "address": "0x6b175474e89094c44da98b954eedeac495271d0f", "metadata": {} }, "metadata": {} }, "amount": { "value": "1238089899992", "currency": { "symbol": "BTC", "decimals": 8, "metadata": { "Issuer": "Satoshi" } }, "metadata": {} }, "coin_change": { "coin_identifier": { "identifier": "0x2f23fd8cca835af21f3ac375bac601f97ead75f2e79143bdf71fe2c4be043e8f:1" }, "coin_action": "coin_created" }, "metadata": { "asm": "304502201fd8abb11443f8b1b9a04e0495e0543d05611473a790c8939f089d073f90509a022100f4677825136605d732e2126d09a2d38c20c75946cd9fc239c0497e84c634e3dd01 03301a8259a12e35694cc22ebc45fee635f4993064190f6ce96e7fb19a03bb6be2", "hex": "48304502201fd8abb11443f8b1b9a04e0495e0543d05611473a790c8939f089d073f90509a022100f4677825136605d732e2126d09a2d38c20c75946cd9fc239c0497e84c634e3dd012103301a8259a12e35694cc22ebc45fee635f4993064190f6ce96e7fb19a03bb6be2" } } ], "metadata": {} }Backward compatible
No
Beta Was this translation helpful? Give feedback.
All reactions