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

merge main to 50 #1544

Closed
Show file tree
Hide file tree
Changes from 38 commits
Commits
Show all changes
72 commits
Select commit Hold shift + click to select a range
2d54a1d
fix: use a constant for badAddress in tx_test.go (#1533)
faddat Jul 24, 2023
36416de
Update CHANGELOG for v0.41.0 release (#1524)
pinosu Jul 28, 2023
8627f85
style: lint wasmd in the same manner as cosmos-sdk (#1537)
faddat Jul 31, 2023
ae964a8
Bump bufbuild/buf-setup-action from 1.25.0 to 1.25.1 (#1541)
dependabot[bot] Aug 3, 2023
7d0752b
better and more minimal update to latest ibc
faddat Aug 4, 2023
d28c43a
golangci-lint run ./... --fix
faddat Aug 4, 2023
8da8c95
fix: use a constant for badAddress in tx_test.go (#1533)
faddat Jul 24, 2023
16686c5
t.Helper()
faddat Aug 4, 2023
a5bb927
lints
faddat Aug 4, 2023
ad0bb8f
t.helper lints
faddat Aug 4, 2023
3dc79d1
Merge commit '2d54a1d3d6925b1080a7f3173f94da929e84882f' into ease-of-…
faddat Aug 4, 2023
4919ec7
Merge commit '36416def20effe47fb77f29f5ba35a003970fdba' into ease-of-…
faddat Aug 4, 2023
75f9385
Merge commit '8627f85275761e69cfb2a535c0e9f48a065485a4' into ease-of-…
faddat Aug 4, 2023
5865608
complete lint changes
faddat Aug 4, 2023
33685a0
add go workspace
faddat Aug 4, 2023
446ee3d
use go 1.20 for tests
faddat Aug 4, 2023
5ec200d
disable tests that need resultvalidatoroutput
faddat Aug 4, 2023
58ffb17
lint
faddat Aug 4, 2023
8fe56ef
use sdkmath in system tests
faddat Aug 4, 2023
67845c6
linter autofixes for test system
faddat Aug 4, 2023
74d37c2
further cleanup for tests
faddat Aug 4, 2023
be20219
use sdkmath in system tests
faddat Aug 4, 2023
8595035
bump linter
faddat Aug 4, 2023
8042bc8
fix testnet so we can run system tests
faddat Aug 4, 2023
46329e7
rebuild protos
faddat Aug 4, 2023
f7763a6
use the upstream simapp
faddat Aug 4, 2023
e9b7263
marshaler to codec and follow sdk simapp reorg
faddat Aug 4, 2023
7ebf30e
bring back some aspects of testnet.go
faddat Aug 4, 2023
c682640
add needed flags
faddat Aug 4, 2023
6edacfe
update for review
faddat Aug 4, 2023
dc970c4
marshaler to codec (#1545)
faddat Aug 4, 2023
a2373f0
remove "check" from make test-all (#1548)
faddat Aug 4, 2023
33df4ae
Bump bufbuild/buf-setup-action from 1.25.1 to 1.26.0 (#1549)
dependabot[bot] Aug 11, 2023
08c517b
Fix label validation error (#1555)
pinosu Aug 17, 2023
3de2c49
Bump bufbuild/buf-setup-action from 1.26.0 to 1.26.1 (#1556)
dependabot[bot] Aug 17, 2023
da28ad4
add Consensus address to autocliopts
hoangdv2429 Aug 21, 2023
37f2df6
use go1.21
faddat Aug 21, 2023
5c678cb
lint
hoangdv2429 Aug 21, 2023
3ca085c
Merge branch 'ease-of-merge-linter-autofixes' of https://github.com/n…
hoangdv2429 Aug 21, 2023
dcee466
revert some logic to set rpc port and setBech32
anhductn2001 Aug 21, 2023
7d9c106
use latest ibc and sdk
faddat Aug 21, 2023
300336d
fix breakages caused by updating cosmos-sdk
faddat Aug 21, 2023
91aeb2b
denom flag be removed in query balance
anhductn2001 Aug 22, 2023
8ddc999
Get balance.amount in raw
anhductn2001 Aug 22, 2023
7078c13
Bump cosmossdk.io/math from 1.0.1 to 1.1.2 (#1566)
dependabot[bot] Aug 22, 2023
c4b99d8
increase defaultSmartQueryGasLimit & clarify logs
hoangdv2429 Aug 22, 2023
fc9d1dc
revert defaultSmartQueryGasLimit
hoangdv2429 Aug 22, 2023
d0e3ed1
Fix gas calculation
chipshort Aug 22, 2023
d325a3c
Merge commit 'd0e3ed1' into ease-of-merge-linter-autofixes
faddat Aug 22, 2023
a6c9cb1
Update config.yml
faddat Aug 23, 2023
881d6a7
Improve ToWasmVMGas/FromWasmVMGas code level documentation (#1564)
webmaster128 Aug 24, 2023
bfaf589
Fix gas calculation (#1567)
chipshort Aug 24, 2023
1028512
Merge remote-tracking branch 'origin/main' into ease-of-merge-linter-…
faddat Aug 24, 2023
9e50a42
Bump actions/checkout from 3.5.3 to 3.6.0 (#1572)
dependabot[bot] Aug 25, 2023
5352b90
last try tonight
hoangdv2429 Aug 25, 2023
3de5127
revert QueryGasLimit
hoangdv2429 Aug 25, 2023
a7df30d
last attempt
hoangdv2429 Aug 25, 2023
749e01a
change msg
hoangdv2429 Aug 25, 2023
86df552
fix a lint and trigger ci
faddat Aug 25, 2023
b015c31
align with sdk
faddat Aug 27, 2023
1f1827e
Revert "align with sdk"
faddat Aug 27, 2023
7705a64
fix lints and make similar to ibc
faddat Aug 27, 2023
9fc6864
format and standardize according to ibc-go upstream
faddat Aug 28, 2023
acfe1e4
fix: make sure wasmvm cache metrics collector after VM setup
dadamu Aug 28, 2023
7c6069d
Merge pull request #1575 from desmos-labs/paul/fix-wasmvm-cache-metri…
alpe Aug 28, 2023
4595e6d
Fail fast on wasmvm cache metric setup
alpe Aug 28, 2023
78b5af2
Merge pull request #1576 from CosmWasm/1575_test
alpe Aug 28, 2023
e937318
Merge remote-tracking branch 'origin/main' into ease-of-merge-linter-…
faddat Aug 30, 2023
e99bb2b
bump sdk
faddat Sep 16, 2023
8c595c8
bump ibc
faddat Sep 16, 2023
cee1cb3
lint
faddat Sep 16, 2023
d662afa
prometheus
faddat Sep 16, 2023
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
26 changes: 13 additions & 13 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ orbs:
executors:
golang:
docker:
- image: cimg/go:1.20
- image: cimg/go:1.21

commands:
make:
Expand All @@ -18,12 +18,12 @@ commands:
- attach_workspace:
at: /tmp/bin
- restore_cache:
name: "Restore source code cache"
name: 'Restore source code cache'
keys:
- go-src-v1-{{ .Revision }}
- checkout
- restore_cache:
name: "Restore go modules cache"
name: 'Restore go modules cache'
keys:
- go-mod-v1-{{ checksum "go.sum" }}
- run:
Expand All @@ -38,7 +38,7 @@ jobs:
steps:
- checkout
- restore_cache:
name: "Restore go modules cache"
name: 'Restore go modules cache'
keys:
- go-mod-v1-{{ checksum "go.sum" }}
- run:
Expand All @@ -48,22 +48,22 @@ jobs:
name: Build
command: make build
- run:
name: "Git garbage collection"
name: 'Git garbage collection'
command: git gc
- save_cache:
name: "Save go modules cache"
name: 'Save go modules cache'
key: go-mod-v1-{{ checksum "go.sum" }}
paths:
- "/go/pkg/mod"
- '/go/pkg/mod'
- save_cache:
name: "Save source code cache"
name: 'Save source code cache'
key: go-src-v1-{{ .Revision }}
paths:
- ".git"
- '.git'

lint:
docker:
- image: golangci/golangci-lint:v1.52.2
- image: golangci/golangci-lint:v1.53.3
steps:
- checkout
- run:
Expand Down Expand Up @@ -94,10 +94,10 @@ jobs:
- persist_to_workspace:
root: /tmp/workspace
paths:
- "profiles/*"
- 'profiles/*'
- store_artifacts:
path: /tmp/logs

test-system:
executor: golang
parallelism: 1
Expand Down Expand Up @@ -190,7 +190,7 @@ jobs:
fi
- when:
condition:
equal: [ main, << pipeline.git.branch >> ]
equal: [main, << pipeline.git.branch >>]
steps:
- run:
name: Push application Docker image to docker hub
Expand Down
118 changes: 104 additions & 14 deletions .golangci.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,26 @@
run:
tests: true
# timeout for analysis, e.g. 30s, 5m, default is 1m
timeout: 5m
build-tags:
- 'system_test'
timeout: 15m
sort-results: true
allow-parallel-runners: true
exclude-dir: testutil/testdata
skip-files:
- server/grpc/gogoreflection/fix_registration.go
- ".*\\.pb\\.go$"
- ".*\\.pb\\.gw\\.\\.go$"
- ".*\\.pulsar\\.go$"

linters:
disable-all: true
enable:
- bodyclose
- dogsled
- errcheck
- dogsled
- exportloopref
- goconst
- gocritic
- gci
- gofumpt
- gosec
- gosimple
Expand All @@ -20,42 +29,123 @@ linters:
- misspell
- nakedret
- nolintlint
- revive
- staticcheck
- revive
- stylecheck
- typecheck
- thelper
- unconvert
- unparam
- unused
- zerologlint

issues:
exclude-rules:
- text: "Use of weak random number generator"
- text: 'Use of weak random number generator'
linters:
- gosec
- text: "ST1003:"
- text: 'ST1003:'
linters:
- stylecheck
# FIXME: Disabled until golangci-lint updates stylecheck with this fix:
# https://github.com/dominikh/go-tools/issues/389
- text: "ST1016:"
- text: 'ST1016:'
linters:
- stylecheck
- path: "migrations"
text: "SA1019:"
- path: 'migrations'
text: 'SA1019:'
linters:
- staticcheck

- text: 'SA1019: codec.NewAminoCodec is deprecated' # TODO remove once migration path is set out
linters:
- staticcheck
- text: 'SA1019: legacybech32.MustMarshalPubKey' # TODO remove once ready to remove from the sdk
linters:
- staticcheck
- text: 'SA1019: legacybech32.MarshalPubKey' # TODO remove once ready to remove from the sdk
linters:
- staticcheck
- text: 'SA1019: legacybech32.UnmarshalPubKey' # TODO remove once ready to remove from the sdk
linters:
- staticcheck
- text: 'SA1019: params.SendEnabled is deprecated' # TODO remove once ready to remove from the sdk
linters:
- staticcheck
- text: 'leading space'
linters:
- nolintlint
max-issues-per-linter: 10000
max-same-issues: 10000

linters-settings:
gci:
custom-order: true
sections:
- standard # Standard section: captures all standard packages.
- default # Default section: contains all imports that could not be matched to another section type.
- prefix(cosmossdk.io)
- prefix(github.com/cosmos/cosmos-sdk)
- prefix(github.com/CosmWasm/wasmd)
revive:
# When set to false, ignores files with "GENERATED" header, similar to golint
ignore-generated-header: true
rules:
- name: redefines-builtin-id
disabled: true

gosec:
# To select a subset of rules to run.
# Available rules: https://github.com/securego/gosec#available-rules
# Default: [] - means include all rules
includes:
# - G101 # Look for hard coded credentials
- G102 # Bind to all interfaces
- G103 # Audit the use of unsafe block
- G104 # Audit errors not checked
- G106 # Audit the use of ssh.InsecureIgnoreHostKey
- G107 # Url provided to HTTP request as taint input
- G108 # Profiling endpoint automatically exposed on /debug/pprof
- G109 # Potential Integer overflow made by strconv.Atoi result conversion to int16/32
- G110 # Potential DoS vulnerability via decompression bomb
- G111 # Potential directory traversal
- G112 # Potential slowloris attack
- G113 # Usage of Rat.SetString in math/big with an overflow (CVE-2022-23772)
- G114 # Use of net/http serve function that has no support for setting timeouts
- G201 # SQL query construction using format string
- G202 # SQL query construction using string concatenation
- G203 # Use of unescaped data in HTML templates
- G204 # Audit use of command execution
- G301 # Poor file permissions used when creating a directory
- G302 # Poor file permissions used with chmod
- G303 # Creating tempfile using a predictable path
- G304 # File path provided as taint input
- G305 # File traversal when extracting zip/tar archive
- G306 # Poor file permissions used when writing to a new file
- G307 # Deferring a method which returns an error
- G401 # Detect the usage of DES, RC4, MD5 or SHA1
- G402 # Look for bad TLS connection settings
- G403 # Ensure minimum RSA key length of 2048 bits
- G404 # Insecure random number source (rand)
- G501 # Import blocklist: crypto/md5
- G502 # Import blocklist: crypto/des
- G503 # Import blocklist: crypto/rc4
- G504 # Import blocklist: net/http/cgi
- G505 # Import blocklist: crypto/sha1
- G601 # Implicit memory aliasing of items from a range statement
misspell:
locale: US
gofumpt:
extra-rules: true
dogsled:
max-blank-identifiers: 6
maligned:
suggest-new: true
nolintlint:
allow-unused: false
allow-leading-space: true
require-explanation: false
require-specific: false
gosimple:
checks: ['all']
gocritic:
disabled-checks:
- regexpMust
- appendAssign
- ifElseChain
33 changes: 32 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,38 @@

## [Unreleased](https://github.com/CosmWasm/wasmd/tree/HEAD)

[Full Changelog](https://github.com/CosmWasm/wasmd/compare/v0.40.2...HEAD)
[Full Changelog](https://github.com/CosmWasm/wasmd/compare/v0.41.0...HEAD)

## [v0.41.0](https://github.com/CosmWasm/wasmd/tree/v0.41.0) (2023-07-28)

[Full Changelog](https://github.com/CosmWasm/wasmd/compare/v0.40.2...v0.41.0)

- Bump IBC-Go to 7.2.0 [\#1459](https://github.com/CosmWasm/wasmd/pull/1459)
- Ensure history position does not conflict [\#1462](https://github.com/CosmWasm/wasmd/pull/1462)
- Bump sequence in ibctests for failed messages [\#1464](https://github.com/CosmWasm/wasmd/pull/1464)
- Accept wasm data from state-sync as valid [\#1467](https://github.com/CosmWasm/wasmd/issues/1467)
- Add updates to ibctesting framework for MS [\#1472](https://github.com/CosmWasm/wasmd/pull/1472)
- Bump CometBFT to v0.37.2 - security fix [\#1479](https://github.com/CosmWasm/wasmd/pull/1479)
- Gov: support contracts that dynamically instantiate other contracts [\#1207](https://github.com/CosmWasm/wasmd/issues/1207)
- Deprecate alias.go [\#1484](https://github.com/CosmWasm/wasmd/pull/1484)
- Upgrade to wasmvm v1.3 [\#1296](https://github.com/CosmWasm/wasmd/issues/1296)
- System tests dependency cleanup [\#1489](https://github.com/CosmWasm/wasmd/pull/1489)
- Allow better override of wasmVM in x/wasm keeper [\#1494](https://github.com/CosmWasm/wasmd/pull/1494)
- Make system tests extendable for other app binaries [\#1503](https://github.com/CosmWasm/wasmd/pull/1503)
- Build release + artifact on CI [\#1515](https://github.com/CosmWasm/wasmd/pull/1515)
- Add/Remove addresses for code upload params [\#1493](https://github.com/CosmWasm/wasmd/pull/1493)
- Bump SDK to v0.47.4 [\#1525](https://github.com/CosmWasm/wasmd/pull/1525)

### Notable changes:
- Bump CometBFT to [v0.37.2](https://github.com/cometbft/cometbft/releases/tag/v0.37.2) because of security issues. See https://github.com/advisories/GHSA-w24w-wp77-qffm
- Support for new wasmvm v1.3.0 capabilities [\#1296](https://github.com/CosmWasm/wasmd/issues/1296)
- Deprecate alias.go [\#1484](https://github.com/CosmWasm/wasmd/pull/1484)
- Gov: support contracts that dynamically instantiate other contracts [\#1207](https://github.com/CosmWasm/wasmd/issues/1207)
- Add/Remove addresses for code upload params [\#1493](https://github.com/CosmWasm/wasmd/pull/1493)

### Migration notes:
- This release does not include any state migrations but breaking changes that require a coordinated chain upgrade.
- This release contains an ibc-go version bump from v7.0.1 to v7.2.0. Please read the [migration guide](https://github.com/cosmos/ibc-go/blob/v7.2.0/docs/migrations/v7-to-v7_1.md) carefully.

## [v0.40.2](https://github.com/CosmWasm/wasmd/tree/v0.40.2) (2023-06-09)

Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ distclean: clean
### Testing

test: test-unit
test-all: check test-race test-cover test-system
test-all: test-race test-cover test-system

test-unit:
@VERSION=$(VERSION) go test -mod=readonly -tags='ledger test_ledger_mock' ./...
Expand Down Expand Up @@ -176,7 +176,7 @@ format: format-tools
###############################################################################
### Protobuf ###
###############################################################################
protoVer=0.13.2
protoVer=0.13.5
protoImageName=ghcr.io/cosmos/proto-builder:$(protoVer)
protoImage=$(DOCKER) run --rm -v $(CURDIR):/workspace --workdir /workspace $(protoImageName)

Expand Down
6 changes: 3 additions & 3 deletions app/ante.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ package app
import (
"errors"

corestoretypes "cosmossdk.io/core/store"
ibcante "github.com/cosmos/ibc-go/v7/modules/core/ante"
"github.com/cosmos/ibc-go/v7/modules/core/keeper"

corestoretypes "cosmossdk.io/core/store"
circuitante "cosmossdk.io/x/circuit/ante"
circuitkeeper "cosmossdk.io/x/circuit/keeper"

sdk "github.com/cosmos/cosmos-sdk/types"
"github.com/cosmos/cosmos-sdk/x/auth/ante"
ibcante "github.com/cosmos/ibc-go/v7/modules/core/ante"
"github.com/cosmos/ibc-go/v7/modules/core/keeper"

wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper"
wasmTypes "github.com/CosmWasm/wasmd/x/wasm/types"
Expand Down
Loading