Make rosetta construction/metadata return the correct default fee #8109
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR fixes an issue with rosetta
construction/metadata
where it returns a hardcoded default transaction fee.Instead of returning the hardcoded fee we now return the default fee from the compile-time config
Mina_compile_config.default_transaction_fee
The test agent (
test-agent/agent.ml
) does not have any test cases using the default fee so required no updates.Testing:
Prior to these changes
construction/metadata
returns a hardcoded fee of 1 Mina. After the change it returns the value from the compile-time constant in one of the.mlh
files.Rosetta will now return the default fee depending on the build profile used. For example, for the production build profile, the
default_transaction_fee
fromsrc/config/amount_defaults/realistic.mlh
will be returned.This can be tested either with the test script
src/app/rosetta/test-curl/con_metadata.sh
or by usingmina_ledger_wallet send-payment
and seeing that the correct default fee is obtained.Checklist:
Closes #8100