Skip to content
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

Pretty print transaction's gas amount in token units #3151

Closed
tjanez opened this issue Jul 30, 2020 · 0 comments · Fixed by #3167
Closed

Pretty print transaction's gas amount in token units #3151

tjanez opened this issue Jul 30, 2020 · 0 comments · Fixed by #3167
Labels
c:cli Category: command line interface c:consensus/cometbft Category: CometBFT

Comments

@tjanez
Copy link
Member

tjanez commented Jul 30, 2020

SUMMARY

Currently, when pretty printing transactions, we display the transaction's fee in base units (but don't tell the user about the unit they are in).

For example:

Hash: 237be76bb6ff593d459e3c282114c49b666fe8a7b27d05affc63ffd607050346
Signer: +yyK5gqJb7x8xPASJZznZk8X8h0ilXuv39ctFYeHlCg=
        (signature: kAR1rwlWgm6eRc0Jjtfnnzq3kKoVJ8C0v9Qvqhs1FilUhxxWXr7rhWUx9pMhx/Wb270ykKnVEx9sXgt7ly5LBw==)
Content:
  Nonce:  7
  Fee:    2000 (gas limit: 1000, gas price: 2)
  Method: staking.Transfer
  Body:
    To:     oasis1qr3jc2yfhszpyy0daha2l9xjlkrxnzas0uaje4t3
    Amount: AMBER 170.0

Change this to also pretty print transaction's gas amount in token units.

For example, something like:

Hash: 237be76bb6ff593d459e3c282114c49b666fe8a7b27d05affc63ffd607050346
Signer: +yyK5gqJb7x8xPASJZznZk8X8h0ilXuv39ctFYeHlCg=
        (signature: kAR1rwlWgm6eRc0Jjtfnnzq3kKoVJ8C0v9Qvqhs1FilUhxxWXr7rhWUx9pMhx/Wb270ykKnVEx9sXgt7ly5LBw==)
Content:
  Nonce:  7
  Fee:
    Amount: AMBER 0.000002
    Gas limit: 1000
  Method: staking.Transfer
  Body:
    To:     oasis1qr3jc2yfhszpyy0daha2l9xjlkrxnzas0uaje4t3
    Amount: AMBER 170.0
ISSUE TYPE
  • Feature Idea
@tjanez tjanez added c:consensus/cometbft Category: CometBFT c:cli Category: command line interface labels Jul 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c:cli Category: command line interface c:consensus/cometbft Category: CometBFT
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant