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

build: Merge wasmd 0.19.0 #444

Merged
merged 92 commits into from
Mar 3, 2022
Merged
Show file tree
Hide file tree
Changes from 87 commits
Commits
Show all changes
92 commits
Select commit Hold shift + click to select a range
5259e0e
Use interface for better decoupling
alpe Jun 1, 2021
e05d786
Allow access to contract address builder
alpe Jun 1, 2021
a170260
Test Pinned contract does not loop forever
alpe Jun 7, 2021
464a024
Cleanup keeper result types
alpe Jun 11, 2021
bebb06c
Verify converted coin
alpe Jun 11, 2021
d11c6e9
revert 0f4ad5b90256b8b1cca6c81286124a10bde26a5c
loloicci Jan 14, 2022
d9b2e65
Empty submsg result does not overwrite
alpe Jun 14, 2021
3d544e1
Store contract response in event (#535)
alpe Jun 14, 2021
06a4dd7
Add cli alias (#536)
alpe Jun 14, 2021
c92fd6d
Charge gas for custom event attributes and messages (#539)
alpe Jun 25, 2021
bef9c35
Empty (non nil) reply data can overwrites response
alpe Jun 25, 2021
fd0a847
Multiply default wasm size by 2
orkunkl Jul 2, 2021
ce08ba1
Fix test
orkunkl Jul 2, 2021
b310fcf
Upgrade wasmvm v0.15.x
alpe Jun 25, 2021
aa71b3c
Upgrade Dockerfile
alpe Jul 7, 2021
660169e
Bump wasmvm and testdata to v0.16.0-rc1
ethanfrey Jul 21, 2021
add2333
IBC Code compiles (non-test)
ethanfrey Jul 21, 2021
3f1d265
Keeper tests pass
ethanfrey Jul 21, 2021
0cc2d14
fix: update tests for wasmvm 0.16.0-rc1
loloicci Feb 8, 2022
7329c21
Update to cosmwasm 0.16.0-rc3 contracts, with some fixes
ethanfrey Jul 21, 2021
310421b
Use _contract_address attribute in emitted events
ethanfrey Jul 21, 2021
72f7622
Reserve all attributes that start with _
ethanfrey Jul 22, 2021
a4f2ff2
Test for events returned from IBC
ethanfrey Jul 22, 2021
3c57d5f
Return custom events from IBC calls as well
ethanfrey Jul 22, 2021
7862abd
Contracts to v0.16.0-rc4, wasmvm to v0.16.0-rc2
ethanfrey Jul 22, 2021
48a2e6d
Fix tests
ethanfrey Jul 22, 2021
1468a35
Add error messages on invalid event attributes
ethanfrey Jul 26, 2021
9d9812f
Tests compile and pass
ethanfrey Jul 26, 2021
b0eed42
Better event tests
ethanfrey Jul 26, 2021
3aaf591
Update with PR comments
ethanfrey Jul 27, 2021
c99018a
Rename 2 fields and regenerate protobuf
ethanfrey Jul 27, 2021
31c2dc0
{Init,Migrate}Msg -> Msg in proposals as well
ethanfrey Jul 27, 2021
d5a0131
Changed references in code - 2 broken tests
ethanfrey Jul 27, 2021
ee8fae7
Rename remaining {Init,Migrate}Msg fields
ethanfrey Jul 27, 2021
545efc3
Update JSON/YAML parsing and test code
ethanfrey Jul 27, 2021
94367c0
Fix up whitespace issues
ethanfrey Jul 27, 2021
67546d7
Fixed remaining PR comments
ethanfrey Jul 27, 2021
39c63e6
Add failing tests showing nothing filtered now
ethanfrey Jul 28, 2021
d775734
Add filtering to logic, tests pass
ethanfrey Jul 28, 2021
e43687a
Update hash algorithm
ethanfrey Jul 27, 2021
de0b22a
Update tests (new default contract addr)
ethanfrey Jul 27, 2021
91cbea3
Almost all tests pass
ethanfrey Jul 27, 2021
4e681e0
Fix last tests
ethanfrey Jul 27, 2021
95ea586
PR Comment: move where truncating address length to 20
ethanfrey Jul 28, 2021
2910453
Remove source, builder from proto files
ethanfrey Jul 27, 2021
ac743f1
x/wasm/types compiles
ethanfrey Jul 27, 2021
840fcf4
x/wasm/keeper compiled
ethanfrey Jul 27, 2021
a3f1a77
keeper and types pass tests
ethanfrey Jul 27, 2021
e8695fa
All code compiles and tests
ethanfrey Jul 27, 2021
5ac2f08
Used reserved keyword in protobuf
ethanfrey Jul 28, 2021
44abeff
Change default message size cost to 0
ethanfrey Jul 27, 2021
8faaec9
Make gas register tests more flexible, fix counting bug
ethanfrey Jul 27, 2021
db51a3b
Adjust gas prices in tests
ethanfrey Jul 27, 2021
6f68f8e
Update comments
ethanfrey Jul 28, 2021
45c1b8d
Change IBCContractKeeper interface, code builds
ethanfrey Jul 28, 2021
d361977
Fix relay tests
ethanfrey Jul 28, 2021
29900c2
Use v0.16.0-rc5 contracts
ethanfrey Jul 28, 2021
9b56e40
Update gas price
ethanfrey Jul 28, 2021
e4fa80a
Remove obsolete cli params
alpe Aug 2, 2021
2a321bf
Add organisation to grpc gateway path
alpe Aug 4, 2021
8e15ff4
update wsamvm 0.16.0-rc3-testing
loloicci Feb 15, 2022
d257c0f
Merge remote-tracking branch 'origin/main' into versionup-19
loloicci Feb 16, 2022
687dfa8
Add contract features to debug logging
alpe Aug 5, 2021
cff4965
update test contracts to cosmwasm v0.16.0
ethanfrey Aug 5, 2021
8219b19
update wasmvm to v0.16.3
loloicci Feb 17, 2022
a219f28
Refactor events
alpe Aug 10, 2021
3e1213d
Update ibc reflect contract from CosmWasm PR 1046
ethanfrey Aug 11, 2021
837608a
Add tests for events
alpe Aug 11, 2021
f7cb906
Strip message events and reorder
alpe Aug 11, 2021
8c15d50
Download cosmwasm contracts
alpe Aug 11, 2021
a6d2d18
Add failing testcase showing messages make it into reply block
ethanfrey Aug 12, 2021
6cb3f03
One more test for message event without reply
ethanfrey Aug 12, 2021
f74f466
Filter messages, fix new tests, break older ones
ethanfrey Aug 12, 2021
5ec7eaf
Update tests to not expect message event
ethanfrey Aug 12, 2021
9e6ca9a
Remove (now-unneeded) filtering in DefaultWasmVMContractResponseHandl…
ethanfrey Aug 12, 2021
c9a890e
Simplify filter method
ethanfrey Aug 12, 2021
231a831
Keeper tests (#590)
husio Aug 27, 2021
b021a58
Add decorator options
alpe Aug 30, 2021
8d96b4d
Fix query handler instantiation
alpe Sep 13, 2021
e519c19
Optimize BalanceQuery
alpe Sep 13, 2021
a90266f
Ensure query isolation (#611)
alpe Sep 14, 2021
dd736f0
chore: go fmt
loloicci Feb 22, 2022
02799b3
chore: remove unused file
loloicci Feb 22, 2022
d7cd656
chore: make format
loloicci Feb 22, 2022
62a6fc6
fix: make lint-fix and fix errors
loloicci Feb 24, 2022
92e4ccf
Merge remote-tracking branch 'origin/main' into versionup-19
loloicci Feb 24, 2022
d412041
chore: make format && make lint-fix
loloicci Feb 24, 2022
5a0f90c
fix: fix proto's comment and update swagger.yaml about proto
loloicci Mar 2, 2022
2308606
build: change depended wasmvm version to 0.16.3-0.9.0
loloicci Mar 3, 2022
994e7b0
fix: remove source and builder option from wasm tx store-and-instanti…
loloicci Mar 3, 2022
9d3c659
docs: update changelog
loloicci Mar 3, 2022
1ff37cf
docs: add removed custom encoder's info to changelog
loloicci Mar 3, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion baseapp/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ import (
"fmt"
"io"

tmdb "github.com/line/tm-db/v2"

"github.com/line/lbm-sdk/store/cache"
"github.com/line/lbm-sdk/store/iavl"
tmdb "github.com/line/tm-db/v2"

"github.com/line/lbm-sdk/codec/types"
"github.com/line/lbm-sdk/snapshots"
Expand Down
3 changes: 2 additions & 1 deletion client/grpc/tmservice/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,14 @@ import (
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"

abci "github.com/line/ostracon/abci/types"

"github.com/line/lbm-sdk/client"
"github.com/line/lbm-sdk/client/rpc"
codectypes "github.com/line/lbm-sdk/codec/types"
cryptotypes "github.com/line/lbm-sdk/crypto/types"
qtypes "github.com/line/lbm-sdk/types/query"
"github.com/line/lbm-sdk/version"
abci "github.com/line/ostracon/abci/types"
)

// This is the struct that we will implement all the handlers on.
Expand Down
1 change: 1 addition & 0 deletions client/keys/add_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import (
"github.com/line/ostracon/libs/cli"

bip39 "github.com/cosmos/go-bip39"

"github.com/line/lbm-sdk/client"
"github.com/line/lbm-sdk/client/flags"
"github.com/line/lbm-sdk/crypto/hd"
Expand Down
3 changes: 2 additions & 1 deletion client/keys/utils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,13 @@ import (
"bytes"
"testing"

"github.com/stretchr/testify/require"

"github.com/line/lbm-sdk/client"
"github.com/line/lbm-sdk/crypto/hd"
"github.com/line/lbm-sdk/crypto/keyring"
"github.com/line/lbm-sdk/testutil"
"github.com/line/lbm-sdk/types"
"github.com/stretchr/testify/require"
)

func Test_printInfos(t *testing.T) {
Expand Down
32 changes: 11 additions & 21 deletions docs/core/proto-docs.md
Original file line number Diff line number Diff line change
Expand Up @@ -11971,8 +11971,6 @@ CodeInfo is data for the uploaded contract WASM code
| ----- | ---- | ----- | ----------- |
| `code_hash` | [bytes](#bytes) | | CodeHash is the unique identifier created by wasmvm |
| `creator` | [string](#string) | | Creator address who initially stored the code |
| `source` | [string](#string) | | Source is a valid absolute HTTPS URI to the contract's source code, optional |
| `builder` | [string](#string) | | Builder is a valid docker image name with tag, optional |
| `instantiate_config` | [AccessConfig](#lbm.wasm.v1.AccessConfig) | | InstantiateConfig access control to apply on contract creation, optional |


Expand Down Expand Up @@ -12186,7 +12184,7 @@ code id.
| `admin` | [string](#string) | | Admin is an optional address that can execute migrations |
| `code_id` | [uint64](#uint64) | | CodeID is the reference to the stored WASM code |
| `label` | [string](#string) | | Label is optional metadata to be stored with a contract instance. |
| `init_msg` | [bytes](#bytes) | | InitMsg json encoded message to be passed to the contract on instantiation |
| `msg` | [bytes](#bytes) | | Msg json encoded message to be passed to the contract on instantiation |
| `funds` | [lbm.base.v1.Coin](#lbm.base.v1.Coin) | repeated | Funds coins that are transferred to the contract on instantiation |


Expand Down Expand Up @@ -12221,7 +12219,7 @@ MsgMigrateContract runs a code upgrade/ downgrade for a smart contract
| `sender` | [string](#string) | | Sender is the that actor that signed the messages |
| `contract` | [string](#string) | | Contract is the address of the smart contract |
| `code_id` | [uint64](#uint64) | | CodeID references the new WASM code |
| `migrate_msg` | [bytes](#bytes) | | MigrateMsg json encoded message to be passed to the contract on migration |
| `msg` | [bytes](#bytes) | | Msg json encoded message to be passed to the contract on migration |



Expand Down Expand Up @@ -12253,8 +12251,6 @@ MsgStoreCode submit Wasm code to the system
| ----- | ---- | ----- | ----------- |
| `sender` | [string](#string) | | Sender is the that actor that signed the messages |
| `wasm_byte_code` | [bytes](#bytes) | | WASMByteCode can be raw or gzip compressed |
| `source` | [string](#string) | | Source is a valid absolute HTTPS URI to the contract's source code, optional |
| `builder` | [string](#string) | | Builder is a valid docker image name with tag, optional |
| `instantiate_permission` | [AccessConfig](#lbm.wasm.v1.AccessConfig) | | InstantiatePermission access control to apply on contract creation, optional |


Expand All @@ -12272,9 +12268,7 @@ MsgStoreCodeAndInstantiateContract submit Wasm code to the system and instantiat
| ----- | ---- | ----- | ----------- |
| `sender` | [string](#string) | | Sender is the that actor that signed the messages |
| `wasm_byte_code` | [bytes](#bytes) | | WASMByteCode can be raw or gzip compressed |
| `source` | [string](#string) | | Source is a valid absolute HTTPS URI to the contract's source code, optional |
| `builder` | [string](#string) | | Builder is a valid docker image name with tag, optional |
| `instantiate_permission` | [AccessConfig](#lbm.wasm.v1.AccessConfig) | | InstantiatePermission access control to apply on contract creation, optional |
| `instantiate_permission` | [AccessConfig](#lbm.wasm.v1.AccessConfig) | | |
| `admin` | [string](#string) | | Admin is an optional address that can execute migrations |
| `label` | [string](#string) | | Label is optional metadata to be stored with a contract instance. |
| `init_msg` | [bytes](#bytes) | | InitMsg json encoded message to be passed to the contract on instantiation |
Expand Down Expand Up @@ -12588,7 +12582,7 @@ InstantiateContractProposal gov proposal content type to instantiate a contract.
| `admin` | [string](#string) | | Admin is an optional address that can execute migrations |
| `code_id` | [uint64](#uint64) | | CodeID is the reference to the stored WASM code |
| `label` | [string](#string) | | Label is optional metadata to be stored with a constract instance. |
| `init_msg` | [bytes](#bytes) | | InitMsg json encoded message to be passed to the contract on instantiation |
| `msg` | [bytes](#bytes) | | Msg json encoded message to be passed to the contract on instantiation |
| `funds` | [lbm.base.v1.Coin](#lbm.base.v1.Coin) | repeated | Funds coins that are transferred to the contract on instantiation |


Expand All @@ -12609,7 +12603,7 @@ MigrateContractProposal gov proposal content type to migrate a contract.
| `run_as` | [string](#string) | | RunAs is the address that is passed to the contract's environment as sender |
| `contract` | [string](#string) | | Contract is the address of the smart contract |
| `code_id` | [uint64](#uint64) | | CodeID references the new WASM code |
| `migrate_msg` | [bytes](#bytes) | | MigrateMsg json encoded message to be passed to the contract on migration |
| `msg` | [bytes](#bytes) | | Msg json encoded message to be passed to the contract on migration |



Expand Down Expand Up @@ -12645,8 +12639,6 @@ StoreCodeProposal gov proposal content type to submit WASM code to the system
| `description` | [string](#string) | | Description is a human readable text |
| `run_as` | [string](#string) | | RunAs is the address that is passed to the contract's environment as sender |
| `wasm_byte_code` | [bytes](#bytes) | | WASMByteCode can be raw or gzip compressed |
| `source` | [string](#string) | | Source is a valid absolute HTTPS URI to the contract's source code, optional |
| `builder` | [string](#string) | | Builder is a valid docker image name with tag, optional |
| `instantiate_permission` | [AccessConfig](#lbm.wasm.v1.AccessConfig) | | InstantiatePermission to apply on contract creation, optional |


Expand Down Expand Up @@ -12734,8 +12726,6 @@ CodeInfoResponse contains code meta data from CodeInfo
| `code_id` | [uint64](#uint64) | | id for legacy support |
| `creator` | [string](#string) | | |
| `data_hash` | [bytes](#bytes) | | |
| `source` | [string](#string) | | |
| `builder` | [string](#string) | | |
| `instantiate_permission` | [AccessConfig](#lbm.wasm.v1.AccessConfig) | | |


Expand Down Expand Up @@ -13013,14 +13003,14 @@ Query provides defines the gRPC querier service

| Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint |
| ----------- | ------------ | ------------- | ------------| ------- | -------- |
| `ContractInfo` | [QueryContractInfoRequest](#lbm.wasm.v1.QueryContractInfoRequest) | [QueryContractInfoResponse](#lbm.wasm.v1.QueryContractInfoResponse) | ContractInfo gets the contract meta data | GET|/wasm/v1/contract/{address}|
| `ContractHistory` | [QueryContractHistoryRequest](#lbm.wasm.v1.QueryContractHistoryRequest) | [QueryContractHistoryResponse](#lbm.wasm.v1.QueryContractHistoryResponse) | ContractHistory gets the contract code history | GET|/wasm/v1/contract/{address}/history|
| `ContractsByCode` | [QueryContractsByCodeRequest](#lbm.wasm.v1.QueryContractsByCodeRequest) | [QueryContractsByCodeResponse](#lbm.wasm.v1.QueryContractsByCodeResponse) | ContractsByCode lists all smart contracts for a code id | GET|/wasm/v1/code/{code_id}/contracts|
| `AllContractState` | [QueryAllContractStateRequest](#lbm.wasm.v1.QueryAllContractStateRequest) | [QueryAllContractStateResponse](#lbm.wasm.v1.QueryAllContractStateResponse) | AllContractState gets all raw store data for a single contract | GET|/wasm/v1/contract/{address}/state|
| `ContractInfo` | [QueryContractInfoRequest](#lbm.wasm.v1.QueryContractInfoRequest) | [QueryContractInfoResponse](#lbm.wasm.v1.QueryContractInfoResponse) | ContractInfo gets the contract meta data | GET|/line/wasm/v1/contract/{address}|
| `ContractHistory` | [QueryContractHistoryRequest](#lbm.wasm.v1.QueryContractHistoryRequest) | [QueryContractHistoryResponse](#lbm.wasm.v1.QueryContractHistoryResponse) | ContractHistory gets the contract code history | GET|/line/wasm/v1/contract/{address}/history|
| `ContractsByCode` | [QueryContractsByCodeRequest](#lbm.wasm.v1.QueryContractsByCodeRequest) | [QueryContractsByCodeResponse](#lbm.wasm.v1.QueryContractsByCodeResponse) | ContractsByCode lists all smart contracts for a code id | GET|/line/wasm/v1/code/{code_id}/contracts|
| `AllContractState` | [QueryAllContractStateRequest](#lbm.wasm.v1.QueryAllContractStateRequest) | [QueryAllContractStateResponse](#lbm.wasm.v1.QueryAllContractStateResponse) | AllContractState gets all raw store data for a single contract | GET|/line/wasm/v1/contract/{address}/state|
| `RawContractState` | [QueryRawContractStateRequest](#lbm.wasm.v1.QueryRawContractStateRequest) | [QueryRawContractStateResponse](#lbm.wasm.v1.QueryRawContractStateResponse) | RawContractState gets single key from the raw store data of a contract | GET|/wasm/v1/contract/{address}/raw/{query_data}|
| `SmartContractState` | [QuerySmartContractStateRequest](#lbm.wasm.v1.QuerySmartContractStateRequest) | [QuerySmartContractStateResponse](#lbm.wasm.v1.QuerySmartContractStateResponse) | SmartContractState get smart query result from the contract | GET|/wasm/v1/contract/{address}/smart/{query_data}|
| `Code` | [QueryCodeRequest](#lbm.wasm.v1.QueryCodeRequest) | [QueryCodeResponse](#lbm.wasm.v1.QueryCodeResponse) | Code gets the binary code and metadata for a singe wasm code | GET|/wasm/v1/code/{code_id}|
| `Codes` | [QueryCodesRequest](#lbm.wasm.v1.QueryCodesRequest) | [QueryCodesResponse](#lbm.wasm.v1.QueryCodesResponse) | Codes gets the metadata for all stored wasm codes | GET|/wasm/v1/code|
| `Code` | [QueryCodeRequest](#lbm.wasm.v1.QueryCodeRequest) | [QueryCodeResponse](#lbm.wasm.v1.QueryCodeResponse) | Code gets the binary code and metadata for a singe wasm code | GET|/line/wasm/v1/code/{code_id}|
| `Codes` | [QueryCodesRequest](#lbm.wasm.v1.QueryCodesRequest) | [QueryCodesResponse](#lbm.wasm.v1.QueryCodesResponse) | Codes gets the metadata for all stored wasm codes | GET|/line/wasm/v1/code|

<!-- end services -->

Expand Down
Loading