Updates cosmos/go-bip39 to version v1.0.0 which
features performance upgrades that bring 12+ searches
down from 24.3us to 1.4us (so 108.33ns per fetch)
after PR https://github.com/cosmos/go-bip39/pull/2.
Files returned by WriteToNewTempFile are cleaned up
automatically at the end of a test case execution.
WriteToNewTempFile now relies on the TB.TempDir()
function provided by the testing std package.
TempFile returns a temporary file that can be used
within a test case and is automatically removed
at the end of the test execution.
* add test case for decoding & re-encoding a full transaction using amino
* drop equal assertion for tx and txRequest
* Fix BroadcastReq UnpackInterfaces
* Remove unrelated files
* order imports
* sort imports again
Co-authored-by: Cory Levinson <cjlevinson@gmail.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
* Recover private validator key
Added the ability to recover the private validator key from a given mnemonic when initializing the node
* Added CHANGELOG entry
* Reverted dependencies
* Added tests
* Fixed mnemonic checking as suggested and added tests
* Run make format and fixed go.sum checksum
* Run make format
* fix imports
* fix TestInitializeNodeValidatorFilesFromMnemonic
* Update CHANGELOG.md
Co-authored-by: Alessio Treglia <quadrispro@ubuntu.com>
Co-authored-by: Alessio Treglia <alessio@tendermint.com>
Co-authored-by: Alessio Treglia <quadrispro@ubuntu.com>
The prior code that tried to get the newest/larger time
between the too performed:
* 2 time.Time.UnixNano() retrievals: 2 multiplications, 2 additions
* 1 math.Max comparison
* 1 time.Unix(0, minTime) creation
but really this code could just use native operations on:
time.Time.After() simply.
This now becomes a single operation, single comparison for the same effect.
* Changelog update
* Rename codec.MarshalAny
* move codec.MarshalInterface to codec.Marshaler
* fix tests
* Update amino_codec for compliance with MarshalerInterface
* update tests and comments
* add tests
* change order of args in UnmarshalInterface to a canonical one
* uplift MarshalInterface to take ProtoMessage as an argument
* wip
* add nil check
* make tests working
* tests cleanup
* add support for *JSON methods
* Update changelog
* linter fixes
* fix test types
* update evidence genesis_test
* adding test
* review updates
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
* x/ibc/core/23-commitment/types: fix MerkleProof.Empty comparisons
Fixes invalid pointer creation, reduces on unnecessary allocations
inside MerkleProof.Empty, and changes the method to a pointer; the
invalid pointer creation was symptomatic of broad use of values.
With this change we have improvements whose benchmarks produce:
```shell
name old time/op new time/op delta
Empty-8 311ns ± 5% 232ns ± 5% -25.49% (p=0.000 n=20+19)
name old alloc/op new alloc/op delta
Empty-8 56.0B ± 0% 8.0B ± 0% -85.71% (p=0.000 n=20+20)
name old allocs/op new allocs/op delta
Empty-8 3.00 ± 0% 1.00 ± 0% -66.67% (p=0.000 n=20+20)
```
Fixes#8091
* Move Empty godoc to right place + add comments for blank*
* x/bank/keeper: fix a missing gRPC error in AllBalances
Fixes an incoherent return which had:
(non-nil value, non-nil-non-grpc error)
to
(nil value, non-nil-gRPC error)
and it is a follow-up of PR #7814.
* types/query: fix pagination test (#8096)
Co-authored-by: Alessio Treglia <alessio@tendermint.com>
* fix: Metadata is not initialized in x/bank InitGenesis #7951
* remove commented code
Co-authored-by: Aleksandr Bezobchuk <alexanderbez@users.noreply.github.com>
The --unarmored-hex and --unsafe flags are added to
the keys export command. Users must use both to
export private keys material. The output would be in
hexadecimal format and unarmored.
See #8042 for scope and motivations.
introduce new UnsafeKeyring interface.
Unsafe operations are supported by UnsafeKeyring types.
By doing so, we try to make the client developer aware
of the risks.
Co-authored-by: Sunny Aggarwal <sunnya97@protonmail.ch>
* Add test that panics
* Add panic in abci query
* Move proto gen files to correct place
* Add panic handler in grpc server
* Fix test
* Fix build
* Use %v
* Better panic message
* Fix tests
Co-authored-by: Aleksandr Bezobchuk <alexanderbez@users.noreply.github.com>
* add IBC prefix to escrow addresses
* use ADR 028 AddressHash construction
* remove extra space
* apply @AdityaSripal suggestion; prefix from ibc -> ibc-transfer-escrow-prefix
* Use alternative 1 proposed by @andrey-kuprianov
* anticpate necessary build fix
* add escrow address issue link into module.go
* Update x/ibc/applications/transfer/types/keys.go
Co-authored-by: Andrey Kuprianov <59489470+andrey-kuprianov@users.noreply.github.com>
* Update x/ibc/applications/transfer/types/keys.go
Co-authored-by: Andrey Kuprianov <59489470+andrey-kuprianov@users.noreply.github.com>
* apply @andrey-kuprianov review suggestions
Deduplicate code into a helper function as suggested. Add unit tests for max transfer channels test.
Co-authored-by: Andrey Kuprianov <59489470+andrey-kuprianov@users.noreply.github.com>