-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[IND-416] Add default fee for v4 python client #54
Conversation
@@ -18,6 +18,7 @@ def prepare_and_broadcast_basic_transaction( | |||
gas_limit: Optional[int] = None, | |||
memo: Optional[str] = None, | |||
broadcast_mode: BroadcastMode = None, | |||
fee: Optional[str] = "5000dv4tnt", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Kind of open questions, but shouldn't fee be required? I think on the protocol it is required. Additionally on mainnet will the token be called dv4tnt
? Not sure if we want to default to this value.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Placing orders does not require a fee.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
set the fee to be 0 if placing an order. We can change the default token when mainnet comes around?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
May make more sense to define a default coin
based on the network in the constants here, and take in both the amount and the coin for the fee in this function, with the defaults set to the 5000
and the coin
in the constants file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
@@ -96,6 +96,9 @@ | |||
|
|||
BECH32_PREFIX = 'dydx' | |||
|
|||
# ------------ DEFAULT TOKEN ------------ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Change the comment to indicate it's the testnet token.
Can we set the fee_denomination here and use that network config in some way instead? |
@@ -93,7 +108,7 @@ def fetchai_stable_testnet(cls): | |||
|
|||
:return: fetchai stable testnet. For now dorado is fetchai stable testnet. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Update this comment?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
@@ -28,6 +28,8 @@ def prepare_and_broadcast_basic_transaction( | |||
:param account: The account | |||
:param gas_limit: The gas limit | |||
:param memo: Transaction memo, defaults to None | |||
:param broadcast_mode: Broadcast mode, defaults to None | |||
:param fee: Transaction fee, defaults to 5000 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Note that the denomination is from the network config.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
No description provided.