Commit Graph

43 Commits

Author SHA1 Message Date
Alessio Treglia e9810ac25c Merge PR #4433: Adopt YAML as human-readable text output 2019-05-31 09:14:34 -04:00
frog power 4000 73e5ef7c13 reduce module interdependancy, /client refactor (#4415)
* abstract staking BuildCreateValidatorMsg, genutil defines its own flags

* client/ refactor

* staking move keys from keeper to types
2019-05-28 09:44:04 +01:00
Alexander Bezobchuk 3153e93446
Merge PR #4356: Update default verifier path 2019-05-17 10:22:33 -04:00
Alexander Bezobchuk 85ffce5f58
Merge PR #4306: Allow generate-only to fully operate offline 2019-05-08 16:06:05 -04:00
Alessio Treglia 93e8f467fe
Turn --from into a positional argument in gaiacli tx send (#4146)
Closes: #4142
2019-04-18 19:48:52 +01:00
Alexander Bezobchuk 0c23dec59f
Merge PR #4135: Minor Fixes
* Add clarification to gen-only
* Add nil type check in NewResponseFormatBroadcastTxCommit
* Add small note to docs re: generate-only
2019-04-16 13:02:36 -04:00
Alexander Bezobchuk 2b43e25d55
Merge PR #3954: Tx Broadcasting Sync by Default 2019-03-25 20:54:23 -04:00
Alexander Bezobchuk 8528ac7665
Merge PR #3960: Disable Keybase for Generate Only in CLI 2019-03-25 11:27:24 -04:00
Jack Zampolin 6f74095ce2
Merge PR #3831: Move indent for json output to 2 spaces 2019-03-08 09:00:17 -08:00
Alexander Bezobchuk feb98bcd05 Merge PR #3698: Prompt User Confirmation Prior to Signing & Broadcasting
* Prompt user confirmation prior to sign & broadcasting
* Update confirmation message
* Update and fix existing CLI integration tests
* Implement CLI integration test for tx confirmation
* Fix order of input into tx send
2019-02-26 12:34:01 +01:00
Alexander Bezobchuk 0611d2eda2 Merge PR #3688: JSON Decode Log in REST Client 2019-02-22 12:54:31 +01:00
Alessio Treglia 9a57ce0214 Merge PR #3514: don't lock keybase on lcd startup 2019-02-06 11:23:49 -08:00
Christopher Goes bc193df8e0
Merge PR #3449: LCD proof verification 2019-01-30 22:48:20 +01:00
Alexander Bezobchuk 90797f5e09 Gaia Lite Generate Only Support (w/o Keybase) (#3396) 2019-01-29 11:22:47 -08:00
Alessio Treglia 493bbaa537 Merge PR #3360: Remove --json flag from all commands
* remove --json flag from all commands and CLIContext

gaiad tendermint show-{address,validator} now take --machine-parseable/-m
for machine parseable output.

Closes: #3249

* Revert machine-parseable thing
2019-01-24 11:15:44 +01:00
Jack Zampolin 9f50c9f5b6
R4R: Ensure all CLI queries respect output flags (#3320) 2019-01-22 09:28:39 -08:00
Jack Zampolin 14ebc65daf Merge PR #3119: Move all store keys into constants
* Move all store keys into constants
* Fix lint issue
* Add Pending.md
* QuerierKey -> QuerierRoute
2018-12-19 20:58:30 +01:00
Federico Kunze 4ecbf0dd5f Merge PR #2997: Split POST delegations endpoint 2018-12-11 15:02:26 +01:00
Alessio Treglia 24a1670cf0 Run make format 2018-12-10 14:27:25 +00:00
Jack Zampolin f525717054
Standardize CLI Exports from Modules (#2840)
* Move query and tx commands to modules
* Move GetAccountDecoder to prevent import cycle and replace calls to it with one call in WithAccountDecoder
* Add moduleClients interface and implement in all applicable modules
* Use module clients in cli initialization
2018-11-19 09:02:34 -08:00
Alexander Bezobchuk 50926fffff Update to TM v0.26.0 - Part I (#2679)
* Update to TM v0.26.0
2018-11-04 18:28:38 -08:00
HaoyangLiu 9f67e8af20 Merge PR #2215: Add swagger-ui for gaiacli lite-server 2018-10-04 13:00:24 +02:00
Christopher Goes 17983460b8
Merge PR #2219: Update to Tendermint 0.24 (except NextValSet offsets) 2018-10-03 17:48:23 +02:00
Jae Kwon 1e26ba2e0e
CLIContext.Logger -> .Output as it isn't a logger (#2420)
This changes .Logger to .Output, as it isn't used anywhere except as os.Stdout.
2018-09-28 21:45:54 -07:00
Matthew Slipper 24413a395d Merge PR #2073: Allow --from to be a name or an address
* Allow --from to be a name or an address

Closes #1735.

* Post-rebase fixes

* Updates from code review

* Updates from code review

* Updates from code review

* Fix merge artifacts

* Fix merge conflicts

* Fix integration tests

* Add back GetFromName() check broken during merge

* Code review updates

* Fix failing test

* Updates from code review
2018-09-25 16:48:38 -04:00
HaoyangLiu d06c589436 Merge PR #2370: Improve error handler in certifier creation 2018-09-21 23:44:39 +08:00
HaoyangLiu 7dc09d0fc2 Merge PR 2210: Judge if trust-node predefined before create certifier add verification for getBlock, queryTx and getValidators (#2210)
Replace trust-node option with distrust-node option, and add varification in getting blocks, transactions and validator sets.
2018-09-15 02:41:21 +08:00
Dev Ojha 6b55093c75 Merge PR #2324: rename wire to codec
* rename wire to codec

* fix formatting and cli

* fix the docs
2018-09-13 14:17:32 -04:00
Alessio Treglia fb0cc0b078 Merge PR #2306: Change --gas=0 semantic and introduce --gas=simulate
* Change --gas=0 semantic and introduce --gas=simulate

Make --gas flag accept a conventional "simulate" string value in addition
to integers. Passing --gas=simulate would trigger the tx simulation and
set the gas according to the gas estimate returned by the simulation.
Any other integer value passed to --gas would be interpreted as-is and
and set as gas wanted value.

Closes: #2300

* Add test cases with gas=0

* ACK suggestion from @alexanderbez

* s/GasFlagSimulateString/GasFlagSimulate/

* Drop TODO comment on Gas type

* Enrich TODO with ref
2018-09-11 20:31:30 -04:00
Alessio Treglia 86395809cb
Implement generate-only option for commands that create txs
The new CLI flag builds an unsigned transaction and writes it to STDOUT.
Likewise, REST clients can now append generate_only=true to a request's
query arguments list and expect a JSON response carrying the unsigned
transaction.

Closes: #966
2018-09-04 02:32:05 +02:00
Alessio Treglia d84885ca49
No need to create a fake slice of signatures nor skip account no./sequence check 2018-08-31 19:09:39 +02:00
Alessio Treglia 1370ca611b
Set GasAdjustment in CLIContext when handling HTTP requests
This is to address @alexanderbez's comments
2018-08-31 19:04:42 +02:00
Alessio Treglia 599923fb99
Introduce simulate mode
Add a simulate only flag '--dry-run' to both CLI tx commands
and RESTful endpoints to trigger the simulation of unsigned
transactions.

* Turning --dry-run on causes the --gas flag to be ignored.
  The simulation will return the estimate of the gas required
  to actually run the transaction.
* Adjustment is no longer required. It now defaults to 1.0.
* In some test cases accounts retrieved from the state do not
  come with a PubKey. In such cases, a fake secp256k1 key is
  generated and gas consumption calculated accordingly.

Closes: #2110
2018-08-31 19:04:11 +02:00
HaoyangLiu 67857d704b IRISHUB-238: change wait 3 second to wait tendermint new block. use MustUnmarshalBinary instead of UnmarshalBinary 2018-08-31 23:20:06 +08:00
HaoyangLiu cb3e729582 IRISHUB-238: fix test_lint failure in context.go 2018-08-31 15:54:15 +08:00
HaoyangLiu b977baec73 IRISHUB-238: move certifier creation to a function 2018-08-31 13:31:24 +08:00
HaoyangLiu 6d2fb8edef IRISHUB-238: fix test_cli failure, move certifier creation from lcd/root.go to NewCLIContext 2018-08-31 11:29:55 +08:00
HaoyangLiu ab76fd964a IRISHUB-238: remove todo, refactor comment and refactor multistoreproof 2018-08-31 10:03:48 +08:00
HaoyangLiu 5e85a5cdcd IRISHUB-238: delete client manager 2018-08-30 17:14:10 +08:00
HaoyangLiu b878edc388 IRISHUB-238: fix failures in test_lint and test_cover 2018-08-30 15:52:17 +08:00
HaoyangLiu 703c643fc0 IRISHUB-238: Add multiply store proof build and verification 2018-08-30 15:05:16 +08:00
Alessio Treglia f432c0c383
Simulate transactions before actual execution
* Change --gas=0 semantic in order to enable gas auto estimate.
* REST clients have been modified to simulate the execution of
  the tx first to then populate the context with the estimated
  gas amount returned by the simulation.
* The simulation returns both an unadjusted gas estimate and an
  adjusted one. The adjustment is required to ensure that the
  ensuing execution doesn't fail due to state changes that might
  have occurred. Gas adjustment can be controlled via the CLI's
  --gas-adjustment flag.
* Tiny refactorig of REST endpoints error handling.

Closes: #1246
2018-08-24 10:16:51 +01:00
Alexander Bezobchuk 12c2c236c2 Merge PR #1741: CoreContext Refactor 2018-08-06 20:11:30 +02:00