Skip to content
This repository was archived by the owner on Nov 25, 2025. It is now read-only.

Commit 25659a0

Browse files
Darioush JalaliholimanMariusVanDerWijdenqdm12
committed
ci: bump golang to 1.23.6 (#805)
Co-authored-by: Martin HS <[email protected]> Co-authored-by: Marius van der Wijden <[email protected]> Co-authored-by: Quentin McGaw <[email protected]>
1 parent ea5897b commit 25659a0

26 files changed

+24
-38
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ jobs:
4343
- name: golangci-lint
4444
uses: golangci/golangci-lint-action@v3
4545
with:
46-
version: v1.56
46+
version: v1.63
4747
working-directory: .
4848
args: --timeout 3m
4949
skip-pkg-cache: true

.golangci.yml

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,6 @@
33
run:
44
timeout: 10m
55
tests: true
6-
# default is true. Enables skipping of directories:
7-
# vendor$, third_party$, testdata$, examples$, Godeps$, builtin$
8-
skip-dirs-use-default: true
9-
# Include non-test files tagged as test-only.
10-
# Context: https://github.com/ava-labs/avalanchego/pull/3173
116

127
linters:
138
disable-all: true
@@ -18,8 +13,19 @@ linters:
1813
- ineffassign
1914
- misspell
2015
- unconvert
16+
- typecheck
2117
- unused
18+
# - staticcheck
19+
- bidichk
20+
- durationcheck
21+
- copyloopvar
2222
- whitespace
23+
# - revive # only certain checks enabled
24+
- durationcheck
25+
- gocheckcompilerdirectives
26+
- reassign
27+
- mirror
28+
- tenv
2329

2430
linters-settings:
2531
gofmt:

RELEASES.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# Release Notes
22

33
## Pending Release
4+
- Bump golang version to v1.23.6
5+
- Bump golangci-lint to v1.63 and add linters
46

57
## [v0.14.1](https://github.com/ava-labs/coreth/releases/tag/v0.14.1)
68

accounts/abi/abi_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1210,7 +1210,6 @@ func TestUnpackRevert(t *testing.T) {
12101210
{"4e487b7100000000000000000000000000000000000000000000000000000000000000ff", "unknown panic code: 0xff", nil},
12111211
}
12121212
for index, c := range cases {
1213-
index, c := index, c
12141213
t.Run(fmt.Sprintf("case %d", index), func(t *testing.T) {
12151214
t.Parallel()
12161215
got, err := UnpackRevert(common.Hex2Bytes(c.input))

accounts/abi/bind/bind.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ func Bind(types []string, abis []string, bytecodes []string, fsigs []map[string]
262262
}
263263
// Parse library references.
264264
for pattern, name := range libs {
265-
matched, err := regexp.Match("__\\$"+pattern+"\\$__", []byte(contracts[types[i]].InputBin))
265+
matched, err := regexp.MatchString("__\\$"+pattern+"\\$__", contracts[types[i]].InputBin)
266266
if err != nil {
267267
log.Error("Could not search for pattern", "pattern", pattern, "contract", contracts[types[i]], "err", err)
268268
}

accounts/abi/event_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -341,7 +341,6 @@ func TestEventTupleUnpack(t *testing.T) {
341341

342342
for _, tc := range testCases {
343343
assert := assert.New(t)
344-
tc := tc
345344
t.Run(tc.name, func(t *testing.T) {
346345
err := unpackTestEventData(tc.dest, tc.data, tc.jsonLog, assert)
347346
if tc.error == "" {

accounts/abi/pack_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ import (
4444
func TestPack(t *testing.T) {
4545
t.Parallel()
4646
for i, test := range packUnpackTests {
47-
i, test := i, test
4847
t.Run(strconv.Itoa(i), func(t *testing.T) {
4948
t.Parallel()
5049
encb, err := hex.DecodeString(test.packed)

accounts/abi/reflect_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,6 @@ var reflectTests = []reflectTest{
182182
func TestReflectNameToStruct(t *testing.T) {
183183
t.Parallel()
184184
for _, test := range reflectTests {
185-
test := test
186185
t.Run(test.name, func(t *testing.T) {
187186
t.Parallel()
188187
m, err := mapArgNamesToStructFields(test.args, reflect.ValueOf(test.struc))

accounts/abi/topics_test.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,6 @@ func TestMakeTopics(t *testing.T) {
147147
},
148148
}
149149
for _, tt := range tests {
150-
tt := tt
151150
t.Run(tt.name, func(t *testing.T) {
152151
t.Parallel()
153152
got, err := MakeTopics(tt.args.query...)
@@ -383,7 +382,6 @@ func TestParseTopics(t *testing.T) {
383382
tests := setupTopicsTests()
384383

385384
for _, tt := range tests {
386-
tt := tt
387385
t.Run(tt.name, func(t *testing.T) {
388386
t.Parallel()
389387
createObj := tt.args.createObj()
@@ -403,7 +401,6 @@ func TestParseTopicsIntoMap(t *testing.T) {
403401
tests := setupTopicsTests()
404402

405403
for _, tt := range tests {
406-
tt := tt
407404
t.Run(tt.name, func(t *testing.T) {
408405
t.Parallel()
409406
outMap := make(map[string]interface{})

accounts/abi/unpack_test.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,6 @@ func TestMethodMultiReturn(t *testing.T) {
399399
"Can not unpack into a slice with wrong types",
400400
}}
401401
for _, tc := range testCases {
402-
tc := tc
403402
t.Run(tc.name, func(t *testing.T) {
404403
require := require.New(t)
405404
err := abi.UnpackIntoInterface(tc.dest, "multi", data)
@@ -957,7 +956,7 @@ func TestOOMMaliciousInput(t *testing.T) {
957956
}
958957
encb, err := hex.DecodeString(test.enc)
959958
if err != nil {
960-
t.Fatalf("invalid hex: %s" + test.enc)
959+
t.Fatalf("invalid hex: %s", test.enc)
961960
}
962961
_, err = abi.Methods["method"].Outputs.UnpackValues(encb)
963962
if err == nil {

0 commit comments

Comments
 (0)