Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
8 changes: 4 additions & 4 deletions .github/workflows/go-client.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
cache: false
- name: golangci-lint
uses: golangci/golangci-lint-action@v8
uses: golangci/golangci-lint-action@v9
with:
version: v2.4
version: v2.10
args: --timeout=10m ./go-client/...

unit-test:
Expand All @@ -34,7 +34,7 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
- name: Build
run: go build -v ./go-client/...
- name: Test (-race)
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
- name: Build
run: go test -run "TestIntegration" -v ./integration_test.go
working-directory: "tests/"
8 changes: 4 additions & 4 deletions .github/workflows/keychain-sdk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
cache: false
- name: golangci-lint
uses: golangci/golangci-lint-action@v8
uses: golangci/golangci-lint-action@v9
with:
version: v2.4
version: v2.10
args: --timeout=10m ./keychain-sdk/...

unit-test:
Expand All @@ -34,7 +34,7 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
- name: Build
run: go build -v ./keychain-sdk/...
- name: Test (-race)
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/shield.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
cache: false
- name: golangci-lint
uses: golangci/golangci-lint-action@v8
uses: golangci/golangci-lint-action@v9
with:
version: v2.4
version: v2.10
args: --timeout=10m ./shield/...

unit-test:
Expand All @@ -34,6 +34,6 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
- name: Test (-race)
run: go test -race -v ./shield/...
8 changes: 4 additions & 4 deletions .github/workflows/soliditygen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
cache: false
- name: golangci-lint
uses: golangci/golangci-lint-action@v8
uses: golangci/golangci-lint-action@v9
with:
version: v2.4
version: v2.10
args: --timeout=10m ./cmd/soliditygen/...

unit-test:
Expand All @@ -34,7 +34,7 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
- name: Build
run: go build -v ./cmd/soliditygen/...
- name: Test (-race)
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/wardend.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
cache: false
- name: golangci-lint
uses: golangci/golangci-lint-action@v8
uses: golangci/golangci-lint-action@v9
with:
version: v2.4
version: v2.10
args: --timeout=10m ${{ env.modules }}

unit-test:
Expand All @@ -47,7 +47,7 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
- name: Build
run: go build -v ${{ env.modules }}
- name: Test (-race)
Expand All @@ -65,4 +65,4 @@ jobs:
uses: ./.github/workflows/release-docker-images.yml
with:
app_name: wardend
secrets: inherit
secrets: inherit
8 changes: 4 additions & 4 deletions .github/workflows/wardenkms.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
cache: false
- name: golangci-lint
uses: golangci/golangci-lint-action@v8
uses: golangci/golangci-lint-action@v9
with:
version: v2.4
version: v2.10
args: --timeout=10m ./cmd/wardenkms/...

unit-test:
Expand All @@ -42,7 +42,7 @@ jobs:
- uses: actions/checkout@v6
- uses: actions/setup-go@v5
with:
go-version: "1.25"
go-version: "1.26"
- name: Build
run: go build -v -o build/wardenkms ./cmd/wardenkms/...
- name: Test (-race)
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Consensus Breaking Changes

- sdk: update Cosmos SDK to v0.53.6.
- x/evm: update cosmos/evm to v0.6.0.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Make the new changelog entry conform to the documented entry format and add impact context.

Line 46 is under Consensus Breaking Changes, but it currently omits the documented (<tag>) #<issue-number> format and lacks upgrade-impact detail.

📝 Proposed changelog update
-- x/evm: update cosmos/evm to v0.6.0.
+- (x/evm) `#1863` update cosmos/evm to v0.6.0 (consensus-breaking; see PR migration notes).

As per coding guidelines, "Assess the documentation for misspellings, grammatical errors, missing documentation and correctness".

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- x/evm: update cosmos/evm to v0.6.0.
- (x/evm) `#1863` update cosmos/evm to v0.6.0 (consensus-breaking; see PR migration notes).
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@CHANGELOG.md` at line 46, The changelog entry "x/evm: update cosmos/evm to
v0.6.0." placed under the "Consensus Breaking Changes" section must be rewritten
to match the documented format and include upgrade impact; change it to the
required "(<tag>) #<issue-number>" suffix (e.g., "(patch) `#1234`") and expand the
description to state the exact change (update of cosmos/evm to v0.6.0) plus a
brief upgrade impact line describing what users must do (e.g., state migration
steps, state compatibility or required node/client updates, and any downtime or
reconfiguration), keeping the entry concise and grammatically correct.


### Features (non-breaking)

Expand Down
6 changes: 6 additions & 0 deletions cmd/clichain/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,14 @@ var generateCmd = &cobra.Command{
keybin := crypto.FromECDSA(key)

w := os.Stdout

if output != "" {
f, err := os.OpenFile(output, os.O_CREATE|os.O_WRONLY, 0o600)
if err != nil {
return fmt.Errorf("opening output file: %w", err)
}
defer f.Close()

w = f
}

Expand All @@ -62,11 +64,13 @@ var publicKeyCmd = &cobra.Command{
}

in := os.Stdin

if keyFile != "" {
f, err := os.Open(keyFile)
if err != nil {
return fmt.Errorf("opening key file: %w", err)
}

in = f
}
Comment on lines 68 to 75
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Close optional input files after opening.

Both branches open a file and rebind in, but never close the file handle. Add defer f.Close() in each branch.

Suggested fix
@@
 		if keyFile != "" {
 			f, err := os.Open(keyFile)
 			if err != nil {
 				return fmt.Errorf("opening key file: %w", err)
 			}
+			defer f.Close()
 
 			in = f
 		}
@@
 		if messageFile != "" {
 			f, err := os.Open(messageFile)
 			if err != nil {
 				return fmt.Errorf("opening message file: %w", err)
 			}
+			defer f.Close()
 
 			in = f
 		}

Also applies to: 142-149

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@cmd/clichain/main.go` around lines 68 - 75, The opened file handles that get
assigned to the shared reader variable in (the branch that opens keyFile and the
other similar branch that also opens a file and rebinds in) are never closed;
after each successful os.Open(keyFile) (where f is the *os.File), add a defer
f.Close() immediately after the open succeeds so the file is closed when the
surrounding function returns (do the same in the other branch that opens and
assigns f to in).


Expand Down Expand Up @@ -134,11 +138,13 @@ var signCmd = &cobra.Command{
}

in := os.Stdin

if messageFile != "" {
f, err := os.Open(messageFile)
if err != nil {
return fmt.Errorf("opening message file: %w", err)
}

in = f
}

Expand Down
2 changes: 1 addition & 1 deletion cmd/wardend/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.25-alpine AS build
FROM golang:1.26-alpine AS build

RUN set -eux; apk add --no-cache ca-certificates build-base linux-headers git curl just;

Expand Down
2 changes: 1 addition & 1 deletion cmd/wardenkms/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM golang:1.25-alpine AS build
FROM golang:1.26-alpine AS build

RUN set -eux; apk add --no-cache ca-certificates build-base linux-headers git curl just;

Expand Down
8 changes: 4 additions & 4 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/warden-protocol/wardenprotocol

go 1.25.0
go 1.26.0

replace (
// use cosmos fork of keyring
Expand Down Expand Up @@ -45,7 +45,7 @@ require (
github.com/cosmos/cosmos-db v1.1.3
github.com/cosmos/cosmos-proto v1.0.0-beta.5
github.com/cosmos/cosmos-sdk v0.53.6
github.com/cosmos/evm v0.5.1
github.com/cosmos/evm v0.6.0
github.com/cosmos/go-bip39 v1.0.0
github.com/cosmos/gogoproto v1.7.2
github.com/cosmos/ibc-go/v10 v10.5.0
Expand Down Expand Up @@ -84,8 +84,8 @@ require (
github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.50.0 // indirect
github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.50.0 // indirect
github.com/bufbuild/protoplugin v0.0.0-20250218205857-750e09ce93e1 // indirect
github.com/bytedance/sonic v1.14.2 // indirect
github.com/bytedance/sonic/loader v0.4.0 // indirect
github.com/bytedance/sonic v1.15.0 // indirect
github.com/bytedance/sonic/loader v0.5.0 // indirect
github.com/cloudwego/base64x v0.1.6 // indirect
github.com/cncf/xds/go v0.0.0-20251022180443-0feb69152e9f // indirect
github.com/envoyproxy/go-control-plane/envoy v1.35.0 // indirect
Expand Down
12 changes: 6 additions & 6 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -839,10 +839,10 @@ github.com/bytedance/gopkg v0.1.3 h1:TPBSwH8RsouGCBcMBktLt1AymVo2TVsBVCY4b6TnZ/M
github.com/bytedance/gopkg v0.1.3/go.mod h1:576VvJ+eJgyCzdjS+c4+77QF3p7ubbtiKARP3TxducM=
github.com/bytedance/sonic v1.5.0/go.mod h1:ED5hyg4y6t3/9Ku1R6dU/4KyJ48DZ4jPhfY1O2AihPM=
github.com/bytedance/sonic v1.9.1/go.mod h1:i736AoUSYt75HyZLoJW9ERYxcy6eaN6h4BZXU064P/U=
github.com/bytedance/sonic v1.14.2 h1:k1twIoe97C1DtYUo+fZQy865IuHia4PR5RPiuGPPIIE=
github.com/bytedance/sonic v1.14.2/go.mod h1:T80iDELeHiHKSc0C9tubFygiuXoGzrkjKzX2quAx980=
github.com/bytedance/sonic/loader v0.4.0 h1:olZ7lEqcxtZygCK9EKYKADnpQoYkRQxaeY2NYzevs+o=
github.com/bytedance/sonic/loader v0.4.0/go.mod h1:AR4NYCk5DdzZizZ5djGqQ92eEhCCcdf5x77udYiSJRo=
github.com/bytedance/sonic v1.15.0 h1:/PXeWFaR5ElNcVE84U0dOHjiMHQOwNIx3K4ymzh/uSE=
github.com/bytedance/sonic v1.15.0/go.mod h1:tFkWrPz0/CUCLEF4ri4UkHekCIcdnkqXw9VduqpJh0k=
github.com/bytedance/sonic/loader v0.5.0 h1:gXH3KVnatgY7loH5/TkeVyXPfESoqSBSBEiDd5VjlgE=
github.com/bytedance/sonic/loader v0.5.0/go.mod h1:AR4NYCk5DdzZizZ5djGqQ92eEhCCcdf5x77udYiSJRo=
github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ=
github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4=
github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM=
Expand Down Expand Up @@ -941,8 +941,8 @@ github.com/cosmos/cosmos-proto v1.0.0-beta.5 h1:eNcayDLpip+zVLRLYafhzLvQlSmyab+R
github.com/cosmos/cosmos-proto v1.0.0-beta.5/go.mod h1:hQGLpiIUloJBMdQMMWb/4wRApmI9hjHH05nefC0Ojec=
github.com/cosmos/cosmos-sdk v0.53.6 h1:aJeInld7rbsHtH1qLHu2aZJF9t40mGlqp3ylBLDT0HI=
github.com/cosmos/cosmos-sdk v0.53.6/go.mod h1:N6YuprhAabInbT3YGumGDKONbvPX5dNro7RjHvkQoKE=
github.com/cosmos/evm v0.5.1 h1:eSRsxFxy/Tr2jiga/h8X5DojnC8JJwd21MB+HTa1SIg=
github.com/cosmos/evm v0.5.1/go.mod h1:AiKOtGMt539qICNH2Kdy+iw9yK3rlcU6MWet3+g8sWs=
github.com/cosmos/evm v0.6.0 h1:jwJerLS7btDgDpZOYy7lUC+1rNRCGGE80TJ6r4guufo=
github.com/cosmos/evm v0.6.0/go.mod h1:QnaJDtxqon2mywiYqxM8VwW8FKeFazi0au0qzVpFAG8=
github.com/cosmos/go-bip39 v1.0.0 h1:pcomnQdrdH22njcAatO0yWojsUnCO3y2tNoV1cb6hHY=
github.com/cosmos/go-bip39 v1.0.0/go.mod h1:RNJv0H/pOIVgxw6KS7QeX2a0Uo0aKUlfhZ4xuwvCdJw=
github.com/cosmos/go-ethereum v1.16.2-cosmos-1 h1:QIaIS6HIdPSBdTvpFhxswhMLUJgcr4irbd2o9ZKldAI=
Expand Down
20 changes: 10 additions & 10 deletions precompiles/act/query.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ func (p *Precompile) ActionsQuery(
ctx sdk.Context,
_ *vm.Contract,
method *abi.Method,
args []interface{},
args []any,
) ([]byte, error) {
req, err := newActionsQuery(method, args)
if err != nil {
Expand All @@ -50,7 +50,7 @@ func (p *Precompile) ActionsQuery(
return method.Outputs.Pack(out)
}

func newActionsQuery(method *abi.Method, args []interface{}) (*types.QueryActionsRequest, error) {
func newActionsQuery(method *abi.Method, args []any) (*types.QueryActionsRequest, error) {
if len(args) != 1 {
return nil, precommon.WrongArgsNumber{Expected: 1, Got: len(args)}
}
Expand All @@ -72,7 +72,7 @@ func (p *Precompile) ActionByIdQuery(
ctx sdk.Context,
_ *vm.Contract,
method *abi.Method,
args []interface{},
args []any,
) ([]byte, error) {
req, err := newActionByIdQuery(args)
if err != nil {
Expand All @@ -96,7 +96,7 @@ func (p *Precompile) ActionByIdQuery(
return method.Outputs.Pack(out)
}

func newActionByIdQuery(args []interface{}) (*types.QueryActionByIdRequest, error) {
func newActionByIdQuery(args []any) (*types.QueryActionByIdRequest, error) {
if len(args) != 1 {
return nil, precommon.WrongArgsNumber{Expected: 1, Got: len(args)}
}
Expand All @@ -116,7 +116,7 @@ func (p *Precompile) ActionsByAddressQuery(
ctx sdk.Context,
_ *vm.Contract,
method *abi.Method,
args []interface{},
args []any,
) ([]byte, error) {
req, err := newActionsByAddressQuery(method, args)
if err != nil {
Expand All @@ -140,7 +140,7 @@ func (p *Precompile) ActionsByAddressQuery(
return method.Outputs.Pack(out)
}

func newActionsByAddressQuery(method *abi.Method, args []interface{}) (*types.QueryActionsByAddressRequest, error) {
func newActionsByAddressQuery(method *abi.Method, args []any) (*types.QueryActionsByAddressRequest, error) {
if len(args) != 3 {
return nil, precommon.WrongArgsNumber{Expected: 3, Got: len(args)}
}
Expand Down Expand Up @@ -168,7 +168,7 @@ func (p *Precompile) TemplatesQuery(
ctx sdk.Context,
_ *vm.Contract,
method *abi.Method,
args []interface{},
args []any,
) ([]byte, error) {
req, err := newTemplatesQuery(method, args)
if err != nil {
Expand All @@ -192,7 +192,7 @@ func (p *Precompile) TemplatesQuery(
return method.Outputs.Pack(out)
}

func newTemplatesQuery(method *abi.Method, args []interface{}) (*types.QueryTemplatesRequest, error) {
func newTemplatesQuery(method *abi.Method, args []any) (*types.QueryTemplatesRequest, error) {
if len(args) != 2 {
return nil, precommon.WrongArgsNumber{Expected: 2, Got: len(args)}
}
Expand Down Expand Up @@ -222,7 +222,7 @@ func (p *Precompile) TemplateByIdQuery(
ctx sdk.Context,
_ *vm.Contract,
method *abi.Method,
args []interface{},
args []any,
) ([]byte, error) {
req, err := newTemplateByIdQuery(args)
if err != nil {
Expand All @@ -246,7 +246,7 @@ func (p *Precompile) TemplateByIdQuery(
return method.Outputs.Pack(out)
}

func newTemplateByIdQuery(args []interface{}) (*types.QueryTemplateByIdRequest, error) {
func newTemplateByIdQuery(args []any) (*types.QueryTemplateByIdRequest, error) {
if len(args) != 1 {
return nil, precommon.WrongArgsNumber{Expected: 1, Got: len(args)}
}
Expand Down
Loading
Loading