Amaury Martiny
55242a659c
Add ADR 031 BaseApp and codec infrastructure ( #7519 )
...
* Refactor RegisterQueryServices -> RegisterServices
* Cleaner proto files
* Fix tests
* Add MsgServer
* Fix lint
* Remove MsgServer from configurator for now
* Remove useless file
* Fix build
* typo
* Add router
* Fix test
* WIP
* Add router
* Remove test helper
* Add beginning of test
* Move test to simapp?
* ServiceMsg implement sdk.Msg
* Add handler by MsgServiceRouter
* Correct signature
* Add full test
* use TxEncoder
* Update baseapp/msg_service_router.go
Co-authored-by: Aaron Craelius <aaron@regen.network>
* Push changes
* WIP on ServiceMsg unpacking
* Make TestMsgService test pass
* Fix tests
* Tidying up
* Tidying up
* Tidying up
* Add JSON test
* Add comments
* Tidying
* Lint
* Register MsgRequest interface
* Rename
* Fix tests
* RegisterCustomTypeURL
* Add changelog entries
* Put in features
* Update baseapp/msg_service_router.go
Co-authored-by: Aleksandr Bezobchuk <alexanderbez@users.noreply.github.com>
* Update baseapp/msg_service_router.go
Co-authored-by: Aleksandr Bezobchuk <alexanderbez@users.noreply.github.com>
* Update baseapp/msg_service_router.go
Co-authored-by: Aleksandr Bezobchuk <alexanderbez@users.noreply.github.com>
* Update baseapp/msg_service_router.go
Co-authored-by: Aleksandr Bezobchuk <alexanderbez@users.noreply.github.com>
* Update baseapp/msg_service_router.go
Co-authored-by: Aleksandr Bezobchuk <alexanderbez@users.noreply.github.com>
* Update baseapp/msg_service_router.go
Co-authored-by: Aleksandr Bezobchuk <alexanderbez@users.noreply.github.com>
* Update baseapp/msg_service_router.go
Co-authored-by: Aleksandr Bezobchuk <alexanderbez@users.noreply.github.com>
* Address review comments
* Address nit
* Fix lint
* Update codec/types/interface_registry.go
Co-authored-by: Marie Gauthier <marie.gauthier63@gmail.com>
* godoc
Co-authored-by: Aaron Craelius <aaronc@users.noreply.github.com>
Co-authored-by: Aaron Craelius <aaron@regen.network>
Co-authored-by: Aleksandr Bezobchuk <alexanderbez@users.noreply.github.com>
Co-authored-by: Marie Gauthier <marie.gauthier63@gmail.com>
2020-10-15 13:07:59 +00:00
Amaury Martiny
7cd25abb87
Proto Tx with Any ( #7276 )
...
* WIP on protobuf keys
* Use Type() and Bytes() in sr25519 pub key Equals
* Add tests
* Add few more tests
* Update other pub/priv key types Equals
* Fix PrivKey's Sign method
* Rename variables in tests
* Fix infinite recursive calls
* Use tm ed25519 keys
* Add Sign and VerifySignature tests
* Remove ed25519 and sr25519 references
* proto linting
* Add proto crypto file
* Implement some of the new multisig proto type methods
* Add tests for MultisigThresholdPubKey
* Add tests for pubkey pb/amino conversion functions
* Move crypto types.go and register new proto pubkeys
* Add missing pointer ref
* Address review comments
* panic in MultisigThresholdPubKey VerifySignature
* Use internal crypto.PubKey in multisig
* Add tests for MultisigThresholdPubKey VerifyMultisignature
* Only keep LegacyAminoMultisigThresholdPubKey and move to proto keys to v1
* Remove conversion functions and introduce internal PubKey type
* Override Amino marshaling for proto pubkeys
* Merge master
* Make proto-gen
* Start removal of old PubKeyMultisigThreshold references
* Fix tests
* Fix solomachine
* Fix ante handler tests
* Pull latest go-amino
* Remove ed25519
* Remove old secp256k1 PubKey and PrivKey
* Uncomment test case
* Fix linting issues
* More linting
* Revert tests keys values
* Add Amino overrides to proto keys
* Add pubkey test
* Fix tests
* Use threshold isntead of K
* Standardize Type
* Revert standardize types commit
* Fix build
* Fix lint
* Fix lint
* Add comment
* Register crypto.PubKey
* Add empty key in BuildSimTx
* Simplify proto names
* Unpack interfaces for signing desc
* Fix IBC tests?
* Format proto
* Use secp256k1 in ibc
* Fixed merge issues
* Uncomment tests
* Update x/ibc/testing/solomachine.go
* UnpackInterfaces for solomachine types
* Remove old multisig
* Add amino marshal for multisig
* Fix lint
* Correctly register amino
* One test left!
* Remove old struct
* Fix test
* Fix test
* Unpack into tmcrypto
* Remove old threshold pubkey tests
* Fix register amino
* Fix lint
* Use sdk crypto PubKey in multisig UnpackInterfaces
* Potential fix?
* Register LegacyAminoPubKey
* Register our own PubKey
* Register tmcrypto PubKey
* Register both PubKeys
* Register interfaces in test
* Refactor fiels
* Add comments
* Use anil's suggestion
* Add norace back
* Check nil
* Address comments
* FIx lint
* Add tests for solomachine unpack interfaces
* Fix query tx by hash
* Better name in amino register
* Display StdTx instead of proto Tx
* Remove useless check
Co-authored-by: Aaron Craelius <aaronc@users.noreply.github.com>
Co-authored-by: blushi <marie.gauthier63@gmail.com>
Co-authored-by: Alexander Bezobchuk <alexanderbez@users.noreply.github.com>
Co-authored-by: colin axnér <25233464+colin-axner@users.noreply.github.com>
2020-09-21 16:48:28 +00:00
SaReN
b2348180b8
Migrate {x/auth, x/gov, x/staking} missing CLI queries to proto ( #6994 )
...
* Fix error code
* Fix decoder
* Fix typo
* Fix decode
* refactor
* Migrate SearchTxsResult to proto
* fix MarkEventsToIndex
* lint++
* Fix output
* Add QueryTxCmd cli test
* Add fmt
* Put txBuilder in types/tx
* Add GetAnyTx in TxBuilder
* Add new IsAnyTx
* Rename to IntoAny
* Fix bug
* fmt
Co-authored-by: Marie <marie.gauthier63@gmail.com>
* Fix ibc CLI to use proto
* Fix any MarshalJSON
* Fix test
* Make tx.Tx implement sdk.Tx
* Register sdk.Tx
* Fix lint
* Allow DefaultJSONTxEncoder to take tx.Tx
* refactor
* Rename variable
* remove fmt
Co-authored-by: Anil Kumar Kammari <anil@vitwit.com>
Co-authored-by: Alexander Bezobchuk <alexanderbez@users.noreply.github.com>
Co-authored-by: Aleksandr Bezobchuk <aleks.bezobchuk@gmail.com>
Co-authored-by: Amaury Martiny <amaury.martiny@protonmail.com>
Co-authored-by: Marie <marie.gauthier63@gmail.com>
2020-09-10 18:26:47 +00:00
Anil Kumar Kammari
64b6bb5270
rename RegisterCodec to RegisterLegacyAminoCodec ( #7243 )
...
* rename RegisterCodec to RegisterLegacyAminoCodec
* Add changelog
* gofmt
* rename codec.New() to codec.NewLegacyAmino()
* Add change log
* Update CHANGELOG.md
Co-authored-by: Amaury Martiny <amaury.martiny@protonmail.com>
* Fix
Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com>
Co-authored-by: Amaury Martiny <amaury.martiny@protonmail.com>
2020-09-07 14:47:12 +00:00
Amaury Martiny
3d969a1ffd
Implement gRPC Simulate endpoint ( #7035 )
...
* Implement simulate endpoint
* Add GetProtoTx()
* Add signing in test
* Add txBuilderFromProto
* Remove stray println
* Update to master
* Merge master
* Fix tests
* Make tests pass
* Integrate in router
* Make proto-gen
* Fix lint
* Really fix lint
* Refactor to fix import cycles
* Rename builder -> wrapper
* Update proto/cosmos/base/reflection/v1beta1/reflection.proto
* Fix after merge
* t->w
Co-authored-by: Alexander Bezobchuk <alexanderbez@users.noreply.github.com>
2020-08-24 14:41:08 +00:00
dauTT
20c80cfd44
Rename *codec.Codec to *codec.LegacyAmino ( #6991 )
...
* Rename *codec.Codec to *codec.LegacyAmino
* Implement requested changes
Co-authored-by: Aaron Craelius <aaron@regen.network>
2020-08-10 19:41:21 +00:00
Marko
a0f9cc7627
vesting: remove alias.go ( #6579 )
2020-07-02 15:08:44 +02:00
Aaron Craelius
712d23740f
Migrate x/auth cmd's to TxGenerator marshaling ( #6391 )
...
* Migrate encode, decode, and broadcast cmd's to use TxGenerator marshal methods
* Fix tests, add EncodingConfig
* Add simapp/encoding.go and wire up with simcli
* add godocs
* fix tests
* Debugging CLI Tests
* Fix integration test
* 6391 - lint issues and code coverage (#6414 )
* fixed lint issue of "txEncodeRespStr"
* added tests for encode.go
* WIP: added tests for decode.go
* added txEncoder at bytes
* updated decode test
* updated txBytes to use TxEncoder in decoder test
* added a require after TxEncoder
* removed file save
* debug decode command
* fixed decode tests
* added decode cli
* updated encode and decode in a single file
* separated decode test from encode test
* review changes
* removed register interface
* review change
* Fix tests
* WIP add test for tx sign
* removed commented code
* Fix flags
* WIP add test for sign
* Address review suggestions
* fixed command issue
* Add tests for TxEncoder
* Revert sign changes
* Fix TxEncoder tests
* Fix GetSign Cmd
* Add tx test
* Remove duplicate validation
* Add tests for TxDecoder
* Fix tests
* Fix tests
* Output to clientCtx.Output
* Fix cli_tests
Co-authored-by: atheeshp <59333759+atheeshp@users.noreply.github.com>
Co-authored-by: atheesh <atheesh@vitwit.com>
Co-authored-by: anilCSE <anil@vitwit.com>
Co-authored-by: sahith-narahari <sahithnarahari@gmail.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
2020-06-18 20:29:41 +00:00
Aaron Craelius
81d647e505
Move codec.RegisterCrypto and codec.Cdc to new packages ( #6330 )
...
* Move codec.Cdc to legacy_global.Cdc
* Update CHANGELOG.md
* Updates
* nit
* Fix imports
* Updates
* Use cosmos multisig instead of tendermint multisig everywhere
* Fix tests
* Rename legacy_global -> legacy
* Add doc.go
* Linting, move all RegisterCrypto calls to crypto/codec
* Update crypto/codec/amino.go
Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com>
2020-06-04 10:38:24 +00:00
SaReN
bf8809ef98
Update x/auth to use Any ( #6165 )
...
* Migrate keeper codec to use marshaler
* Migrate AccountI to types
* Did go imports
* Fix tests for x/auth
* Cleanup std/codec
* Sort imports
* Fix legacy codec
* Add godoc for RegisterInterfaces
* Add RegisterInterfaces to std
* Fix typo
* Fixed merge changes
* Eliminate vesting import in auth
* Fix lint issues
* Fix tests
* Addressed comments
* Rename interfaces in RegisterInterfaces
* Removed codec.proto from std
* Minor code cleanup
Co-authored-by: Aaron Craelius <aaron@regen.network>
2020-05-20 19:21:00 +00:00
Aaron Craelius
70767c87c4
Update x/gov to use Any ( #6147 )
...
* Update x/gov to use Any
* Fixes
* Remove MsgSubmitProposalLegacy
* Update CHANGELOG.md
* Add RegisterInterfaces for x/distribution, x/params, & x/upgrade
* Fix query JSON issue
* Fix gov tests
* Revert custom Any Equals
* Re-remove types
* Rename receivers
* Fix imports in gov
* Sort imports
* Make amino JSON signing work with Any
* Run proto-gen
* Create full amino wrapper
* Fix errors
* Fixes
* Fix tests
* Test fixes
* Fix tests
* Linting
* Update ADR 019 and CHANGELOG
* Updated ADR 019
* Extract Marshal/UnmarshalProposal
* fix error
* lint
* linting
* linting
* Update client/keys/parse.go
Co-authored-by: Marko <marbar3778@yahoo.com>
* linting
* Update docs/architecture/adr-019-protobuf-state-encoding.md
Co-authored-by: Alexander Bezobchuk <alexanderbez@users.noreply.github.com>
* Update docs/architecture/adr-019-protobuf-state-encoding.md
Co-authored-by: Alexander Bezobchuk <alexanderbez@users.noreply.github.com>
* Address review feedback
* Add godocs
* Fix errors
* fix errors
* revert file
* Address review feedback
* Address review feedback
* Stacktrace debug flag
* Fix tests
* Address review feedback
Co-authored-by: sahith-narahari <sahithnarahari@gmail.com>
Co-authored-by: Marko <marbar3778@yahoo.com>
Co-authored-by: Alexander Bezobchuk <alexanderbez@users.noreply.github.com>
2020-05-19 20:17:29 +00:00
atheeshp
da92383bff
Bank proto buf migration ( #6166 )
...
* Bank proto buf migration
* WIP: Added proto code for bank
* added supply on bank module
* Bank module proto migration
* formatter applied
* Added comment for RegisterInterfaceTypes in bank/module
2020-05-12 17:35:05 +00:00
Aaron Craelius
386217209d
Merge PR #6076 : Proto Any init + evidence
2020-05-05 10:28:20 -04:00
Aaron Craelius
cc90f2e002
Merge pull request #6085 : Move codec/std to std
2020-04-27 15:40:50 -04:00