* Add shorthand flag to address output on gaiacli keys show
* Update docs and add PENDING
* Update client/keys/show.go
Co-Authored-By: jackzampolin <jack.zampolin@gmail.com>
* pk -> p
* Fix gaiacli config and make it non-interactive only
Closes: #2734
* Update cli tests
* Remove --list, by default and with no args print config
* Small improvements
* Warn user when file doesn't exist
* Fix integration tests
* add --force to keys delete for unattended execution
Skip password check when --force is on and delete
keys unconditionally.
Closes: #2961
* Forcibly cleanup keys on fixtures initialization
* Force password to 'yes' when deleting ledger-offline keys
* Improve UX, better docs on removing offline/ledger keys
* Ask for confirmation on offline/ledger keys deletion
* Fix tag usage in handlers and EndBlocker
* Prepend action tag in baseApp
* Fix LCD
* Remove unnecessary conversion
* Fix invalid consensus pubkey in CLI tests
* Fix tag usage in cli_test
* Shorten bechify in test
* Update docs and PENDING
* Make simulator operations predetermined
* Use new dbm.ReverseIterator API
* Simulation speed improvements
* Pin exact revisions, not branches
* Rename 'MountStoresIAVL' to 'MountStores'
* Zero Power Block fees to community pool
Throughout the codebase the misspelling 'depositer' of the English word
'depositor' has been used. This commit applies a global search and
replace to correct the misspelling.
* gaiad gentx subcommands refactoring
- Replace STDIN/STDOUT redirection in `gaiad gentx` with subcommands
command line options to redirect streams to file since viper does
not handle redirection well.
- Use `BuildCreateValidatorMsg` to build a `MsgCreateValidator` rather
than redirecting to `gaiacli tx stake create-validator`.
- `PrintUnsignedStdTx` now takes an `io.Writer` object.
- Mark `--pubkey`, `--amount` and `--moniker` as required flags
instead of validating them manually.
- Use stake.NewDescription() to make a new Description - ref #2835
* Refresh PENDING.md
* 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
New genesis workflow:
* `gaiad init` is now used to generate an empty `genesis.json`.
* Genesis accounts need to be populated manually before running
`gaiad collect-gentxs`.
* This should support starfish too, see #2615 for more info.
* Closes: #2596#2615
* Validate validator address and address against respective account ex ante
* Fix local testnet failures
* New genesis tests
* Run make format
* Add --pubkey flag
* gaiad collect-gentxs takes no args
Make simulation use a transition matrix for block size
This enables simulating periods of high load, and periods of low to no load.
(low load because future ops will still terminate in that time frame)
- Exit with error if the user is attempting to sign with a key
whose address is not among those who are expected to sign
the transaction.
- Add --print-signature-only to output only the generated
signature.
Rework the process of loading a genesis.json file to load a starting app state and set of initial transactions to process.
* New function to create genesis account from MsgCreateValidator
* Add arg to PrintUnsignedStdTx() to actually operate in offline mode
* New func processStdTxs()
* Remove gen-tx command
* Cleanup, return validators as they need to be written into genesis.json
* Modify gaiad init to allow auto-create of stdTx
* Remove server/testnet.go
* Don't load node_key.json, which might not be available
* Get the txs through DeliverTx
* Add app.slashingKeeper.AddValidators at the end of genesis
* On InitChain(), Signature's account number must be 0
* Add (tentative?) command to generate {node_key,priv_validator}.json files
* Reintroduce gaiad testnet
* Prompt user for passwords
* Update gaia to work with auth.StdTx
* Remove test_utils, NewTestGaiaAppGenState is now deprecated
* Combine --genesis-format and --generate-only
* Improve sign command's --offline flag documentation
* Moniker must be set
* Call app.slashingKeeper.AddValidators() even if len(txs) == 0
* Refactoring, introduce gaiad init --skip-genesis, code cleanup
* Drop unnecessary workaround to make lcd_tests pass
* Reintroduce gentx
* Simple name changes, GenesisState.Txs -> .GenTxs; OWK -> OverwriteKey; OverwriteKeys -> OverwriteKey
* crypto/keys/hd: use btcec to remove dep on tendermint
* crypto/keys/bcrypt: improve comment about fork
* crypto/keys/bip39 -> crypto/keys/bip39/fundraiser
* crypto/keys/bip39: bring in fork of tyler-smith
* crypto/keys/hd: update dep
* crypto/keys: update deps
* crypto/keys: move mintkey.go into new crypto/keys/mintkey
* crypto/keys/hd: NewParamsFromPath
* crypto/keys: keybase.Derive takes a bip39 passphrase too
* crypto/keys/hd: BIP44Params.DerivationPath
* gaiacli keys: add commands new and mnemonic
* fix lints
* minor fixes from review
* update Gopkg.toml
* add tendermint fork of golang.org/x/crypto
* pin some transitive deps
* crypto/keys/bcrypt: remove
* remove in favour of fork of golang.org/x/crypto/bcrypt at github.com/tendermint/crypto/bcrypt
* crypto/keys/bip39: remove completely
* use fork cosmos/go-bip39 instead
* Gopkg.toml: dont use master
* Pull in changes from my PR
* fixes from review
* enforce min len for --unsafe-entropy
* lint fix
* feedback from review
* fix dep
* Add arg to PrintUnsignedStdTx() to actually operate in offline mode
* WIP simplifying server module
* Expose ExternalIP()
* Move {GenTx,Init}Cmd into gaia's new init package
This is basically copying over @anton's great script!
Also had to run `make format` to make this pass `test_lint`.
This PR also makes the make commands for tools further align
with the tendermint implementation.
* Refactor InitializeTestLCD to initialize correctly
* Update InitializeTestLCD API usage in LCD unit tests
* Update pending log
* Update named return variables
* Increase power of validator proposer in LCD tests
* Allow a gaia-cli config file to be created
Closes#1613.
Closes#1275.
Closes#1956.
* Add homedir to Gopkg.toml
* Updates from code review
* Post-rebase fixes
* Update test
* Code review refactor
* Fixes from code review
* Fix import
* Fix broken test
* Fixes from rebase
* Fix formatting
* 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
In order to guarantee a secure connection between apps and the LCD the
communication must be encrypted - even if clients and server run on the
same local machine, credentials must never be transmitted in clear text.
Upon start up, the server generates a self-signed certificate and a key.
Both are stored as temporary files; removal is guaranteed on exit.
This new behaviour is now enabled by default, though users are provided
with a --insecure flag to switch it off.
* Cherry picked commits from prev branch
* Added new keepers for querier functionalities
* Renaming
* Fixed gov errors and messages
* Added Querier to stake and app
* Update delegation keepers
* REST Queriers not working
* Fix marshalling error
* Querier tests working
* Pool and params working
* sdk.NewCoin for test handler
* Refactor and renaming
* Update LCD queries and added more tests for queriers
* use sdk.NewCoin
* Delegator summary query and tests
* Added more tests for keeper
* Update PENDING.md
* Update stake rest query
* Format and replaced panics for sdk.Error
* Refactor and addressed comments from Sunny and Aleks
* Fixed some of the errors produced by addr type change
* Fixed remaining errors
* Updated and fixed lite tests
* JSON Header and consistency on errors
* Increased cov for genesis
* Added comment for maxRetrieve param in keepers
* Comment on DelegationWithoutDec
* Bech32Validator Keepers
* Changed Bech validator
* Updated remaining tests and bech32 validator
* Addressed most of Rigel's comments
* Updated tests and types
* Make codec to be unexported from keeper
* Moved logic to query_utils and updated tests
* Fix linter err and PENDING
* Fix err
* Fix err
* Fixed tests
* Update PENDING description
* Update UpdateBondedValidatorsFull
* Update iterator
* defer iterator.Close()
* delete comment
* Address some of Aleks comments, need to fix tests
* export querier
* Fixed tests
* Address Rigel's comments
* More tests
* return error for GetDelegatorValidator
* Fixed conflicts
* Fix linter warnings
* Address @rigelrozanski comments
* Delete comments
* wire ––> codec
* 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
- replace with and unexported struct and amino's ability to override /
implement MarshalJSON & UnmarshalJSON to have the pub key bechified
- replaced default time to UTC as I (from London) always got an error
while decoding (epoch but in BST ;-)
- remove all occurrences of `BechValidator
* Add sign CLI command to sign transactions generated with the
--generate-only flag.
* Add /sign REST endpoint for Voyager support.
Redirect password prompt to STDERR to avoid messing up cli
commands output. As a rule of thumb, program's output should
always go to STDOUT, whilst errors&diagnostics go to STDERR
as per POSIX's philosophy and specs.
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
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
* Add new account bech32 prefixes with godocs
* Restructure spacing of existing account code
* Update account godocs
* More account godoc updates + new tm pub/addr helpers
* Update validator type to use new account types/bech32 prefixes
* Fix account documentation errors
* Update Bech32 prefix for consensus nodes
* Update Bech32 spec doc
* Fix account type tests
* Add missing account consensus functions, clear up godocs, and fix tests
* Add to TestRandBech32PubkeyConsistency check
* Update initialization of validator public keys
* Update query signing info command
* Implement new ConsAddress type with associated unit tests
* [WIP] Update stake and slashing parameters
* Update all calls to MustBech32ifyValPub
* [WIP] Validator operator API updates
* [WIP] Fix and update unit tests
* Fix gov logs (helping to debug failing tests)
* Fix gov tally
* Fix all broken x/ unit tests
* Update gaia app genesis address logic
* Fix linting errors
* Fix broken LCD tests
* Fix broken CLI tests
* Implement command to get validator address and pubkey from key name
* Add support for getting validator key information via REST endpoint
* Update PENDING log
* Update docs
* Revert GaiaGenTx.PubKey bech32 prefix
* Fix broken docs and cli tests
* Update genesis to use correct Bech32 (cons) prefix for pubkeys
* Update docs and unit tests to reflect new cosmos account bech32 prefix
* minor formatting
* 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