Skip to content

Commit 8d4cd85

Browse files
Bump golangci/golangci-lint-action from 6 to 7 in the github-actions group (#31)
Bumps the github-actions group with 1 update: [golangci/golangci-lint-action](https://github.com/golangci/golangci-lint-action). Updates `golangci/golangci-lint-action` from 6 to 7 <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/golangci/golangci-lint-action/releases">golangci/golangci-lint-action's releases</a>.</em></p> <blockquote> <h2>v7.0.0</h2> <!-- raw HTML omitted --> <p>⚠️ <strong>The GitHub Action v7 supports golangci-lint v2 only.</strong> ⚠️</p> <h2>What's Changed</h2> <h3>Changes</h3> <ul> <li>feat: golangci-lint v2 support by <a href="https://github.com/ldez"><code>@​ldez</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1198">golangci/golangci-lint-action#1198</a></li> </ul> <h3>Documentation</h3> <ul> <li>docs: update annotation permissions by <a href="https://github.com/ldez"><code>@​ldez</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1203">golangci/golangci-lint-action#1203</a></li> <li>docs: fix checks permissions for annotations by <a href="https://github.com/kema-dev"><code>@​kema-dev</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1204">golangci/golangci-lint-action#1204</a></li> </ul> <h3>Dependencies</h3> <ul> <li>build(deps-dev): bump the dev-dependencies group with 3 updates by <a href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1207">golangci/golangci-lint-action#1207</a></li> </ul> <h2>New Contributors</h2> <ul> <li><a href="https://github.com/kema-dev"><code>@​kema-dev</code></a> made their first contribution in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1204">golangci/golangci-lint-action#1204</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/golangci/golangci-lint-action/compare/v6.5.2...v7.0.0">https://github.com/golangci/golangci-lint-action/compare/v6.5.2...v7.0.0</a></p> <h2>v6.5.2</h2> <!-- raw HTML omitted --> <h2>What's Changed</h2> <h3>Changes</h3> <ul> <li>fix: update max version by <a href="https://github.com/ldez"><code>@​ldez</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1201">golangci/golangci-lint-action#1201</a></li> </ul> <h3>Dependencies</h3> <ul> <li>build(deps-dev): bump the dev-dependencies group with 2 updates by <a href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1199">golangci/golangci-lint-action#1199</a></li> </ul> <p><strong>Full Changelog</strong>: <a href="https://github.com/golangci/golangci-lint-action/compare/v6.5.1...v6.5.2">https://github.com/golangci/golangci-lint-action/compare/v6.5.1...v6.5.2</a></p> <h2>v6.5.1</h2> <!-- raw HTML omitted --> <h2>What's Changed</h2> <h3>Changes</h3> <ul> <li>fix: octokit retry by <a href="https://github.com/ldez"><code>@​ldez</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1193">golangci/golangci-lint-action#1193</a></li> <li>feat: restrict action v6 on golangci-lint v1 by <a href="https://github.com/ldez"><code>@​ldez</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1194">golangci/golangci-lint-action#1194</a></li> </ul> <h3>Documentation</h3> <ul> <li>docs: add notes for annotation config by <a href="https://github.com/dveeden"><code>@​dveeden</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1173">golangci/golangci-lint-action#1173</a></li> <li>docs: improve verify option explanation by <a href="https://github.com/ldez"><code>@​ldez</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1175">golangci/golangci-lint-action#1175</a></li> </ul> <h3>Dependencies</h3> <ul> <li>build(deps-dev): bump the dev-dependencies group with 3 updates by <a href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1177">golangci/golangci-lint-action#1177</a></li> <li>build(deps): bump the dependencies group with 2 updates by <a href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1178">golangci/golangci-lint-action#1178</a></li> <li>build(deps): bump <code>@​octokit/request</code> from 8.4.0 to 8.4.1 by <a href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1181">golangci/golangci-lint-action#1181</a></li> <li>build(deps-dev): bump the dev-dependencies group with 3 updates by <a href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1185">golangci/golangci-lint-action#1185</a></li> <li>build(deps): bump <code>@​types/node</code> from 22.13.4 to 22.13.5 in the dependencies group by <a href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1186">golangci/golangci-lint-action#1186</a></li> <li>build(deps): bump <code>@​octokit/plugin-paginate-rest</code> from 9.2.1 to 9.2.2 by <a href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1187">golangci/golangci-lint-action#1187</a></li> <li>build(deps): bump the dependencies group with 2 updates by <a href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1189">golangci/golangci-lint-action#1189</a></li> <li>build(deps-dev): bump the dev-dependencies group across 1 directory with 5 updates by <a href="https://github.com/dependabot"><code>@​dependabot</code></a> in <a href="https://redirect.github.com/golangci/golangci-lint-action/pull/1190">golangci/golangci-lint-action#1190</a></li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/golangci/golangci-lint-action/commit/1481404843c368bc19ca9406f87d6e0fc97bdcfd"><code>1481404</code></a> 7.0.0</li> <li><a href="https://github.com/golangci/golangci-lint-action/commit/dec74fa03096ff515422f71d18d41307cacde373"><code>dec74fa</code></a> feat: golangci-lint v2 support (<a href="https://redirect.github.com/golangci/golangci-lint-action/issues/1198">#1198</a>)</li> <li><a href="https://github.com/golangci/golangci-lint-action/commit/1f07148fa0c704709f56ae92884ec7fc9d19a413"><code>1f07148</code></a> build(deps-dev): bump the dev-dependencies group with 3 updates (<a href="https://redirect.github.com/golangci/golangci-lint-action/issues/1207">#1207</a>)</li> <li><a href="https://github.com/golangci/golangci-lint-action/commit/9938e103f8065deff3f289d9e975270d5541b866"><code>9938e10</code></a> docs: fix checks permissions for annotations (<a href="https://redirect.github.com/golangci/golangci-lint-action/issues/1204">#1204</a>)</li> <li><a href="https://github.com/golangci/golangci-lint-action/commit/b91d580160cdcb5498a14265c2b329fdc9d62f0a"><code>b91d580</code></a> docs: update annotation permissions (<a href="https://redirect.github.com/golangci/golangci-lint-action/issues/1203">#1203</a>)</li> <li>See full diff in <a href="https://github.com/golangci/golangci-lint-action/compare/v6...v7">compare view</a></li> </ul> </details> <br /> [![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=golangci/golangci-lint-action&package-manager=github_actions&previous-version=6&new-version=7)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore <dependency name> major version` will close this group update PR and stop Dependabot creating any more for the specific dependency's major version (unless you unignore this specific dependency's major version or upgrade to it yourself) - `@dependabot ignore <dependency name> minor version` will close this group update PR and stop Dependabot creating any more for the specific dependency's minor version (unless you unignore this specific dependency's minor version or upgrade to it yourself) - `@dependabot ignore <dependency name>` will close this group update PR and stop Dependabot creating any more for the specific dependency (unless you unignore this specific dependency or upgrade to it yourself) - `@dependabot unignore <dependency name>` will remove all of the ignore conditions of the specified dependency - `@dependabot unignore <dependency name> <ignore condition>` will remove the ignore condition of the specified dependency and ignore conditions </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 parent 1819598 commit 8d4cd85

4 files changed

Lines changed: 31 additions & 19 deletions

File tree

.github/workflows/golang.yaml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
steps:
2020
- uses: actions/setup-go@v5
2121
with:
22-
go-version: '1.22.2'
22+
go-version: '1.24.1'
2323
cache-dependency-path: "**/*.sum"
2424
- uses: actions/checkout@v4
2525
- run: go mod verify
@@ -31,7 +31,7 @@ jobs:
3131
steps:
3232
- uses: actions/setup-go@v5
3333
with:
34-
go-version: '1.22.2'
34+
go-version: '1.24.1'
3535
cache-dependency-path: "**/*.sum"
3636
- uses: actions/checkout@v4
3737
- run: go mod verify
@@ -44,7 +44,7 @@ jobs:
4444
steps:
4545
- uses: actions/setup-go@v5
4646
with:
47-
go-version: '1.22.2'
47+
go-version: '1.24.1'
4848
cache-dependency-path: "**/*.sum"
4949
- uses: actions/checkout@v4
5050
- run: go mod verify
@@ -61,7 +61,7 @@ jobs:
6161
steps:
6262
- uses: actions/setup-go@v5
6363
with:
64-
go-version: '1.22.2'
64+
go-version: '1.24.1'
6565
cache-dependency-path: "**/*.sum"
6666
- uses: actions/checkout@v4
6767
- run: go vet ./...
@@ -78,17 +78,17 @@ jobs:
7878
steps:
7979
- uses: actions/setup-go@v5
8080
with:
81-
go-version: '1.22.2'
81+
go-version: '1.24.1'
8282
cache-dependency-path: "**/*.sum"
8383
- uses: actions/checkout@v4
84-
- uses: golangci/golangci-lint-action@v6
84+
- uses: golangci/golangci-lint-action@v7
8585
with:
86-
version: 'v1.57.2'
87-
- uses: golangci/golangci-lint-action@v6
86+
version: 'v2.0.1'
87+
- uses: golangci/golangci-lint-action@v7
8888
with:
8989
working-directory: 'fuzz'
90-
version: 'v1.57.2'
91-
- uses: golangci/golangci-lint-action@v6
90+
version: 'v2.0.1'
91+
- uses: golangci/golangci-lint-action@v7
9292
with:
9393
working-directory: 'integration'
94-
version: 'v1.57.2'
94+
version: 'v2.0.1'

filter/util.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ func isValidPostgresIdentifier(s string) bool {
5858
}
5959

6060
// The first character needs to be a letter or _
61-
if !(s[0] >= 'a' && s[0] <= 'z') && !(s[0] >= 'A' && s[0] <= 'Z') && s[0] != '_' {
61+
if (s[0] < 'a' || s[0] > 'z') && (s[0] < 'A' || s[0] > 'Z') && s[0] != '_' {
6262
return false
6363
}
6464

integration/postgres_test.go

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@ func TestIntegration_ReadmeExample(t *testing.T) {
7373
if err != nil {
7474
t.Fatal(err)
7575
}
76-
defer rows.Close()
7776
ids := []int{}
7877
for rows.Next() {
7978
var id int
@@ -82,6 +81,9 @@ func TestIntegration_ReadmeExample(t *testing.T) {
8281
}
8382
ids = append(ids, id)
8483
}
84+
if err := rows.Err(); err != nil {
85+
t.Fatal(err)
86+
}
8587

8688
if len(ids) != 2 {
8789
t.Fatalf("expected 2 rows, got %d", len(ids))
@@ -137,7 +139,6 @@ func TestIntegration_InAny_PQ(t *testing.T) {
137139
if err != nil {
138140
t.Fatal(err)
139141
}
140-
defer rows.Close()
141142
ids := []int{}
142143
for rows.Next() {
143144
var id int
@@ -146,6 +147,9 @@ func TestIntegration_InAny_PQ(t *testing.T) {
146147
}
147148
ids = append(ids, id)
148149
}
150+
if err := rows.Err(); err != nil {
151+
t.Fatal(err)
152+
}
149153

150154
if len(ids) != 8 {
151155
t.Fatalf("expected 8 rows, got %d", len(ids))
@@ -202,7 +206,6 @@ func TestIntegration_InAny_PGX(t *testing.T) {
202206
if err != nil {
203207
t.Fatal(err)
204208
}
205-
defer rows.Close()
206209
ids := []int{}
207210
for rows.Next() {
208211
var id int
@@ -211,6 +214,9 @@ func TestIntegration_InAny_PGX(t *testing.T) {
211214
}
212215
ids = append(ids, id)
213216
}
217+
if err := rows.Err(); err != nil {
218+
t.Fatal(err)
219+
}
214220

215221
if len(ids) != 8 {
216222
t.Fatalf("expected 8 rows, got %d", len(ids))
@@ -466,7 +472,6 @@ func TestIntegration_BasicOperators(t *testing.T) {
466472
}
467473
return
468474
}
469-
defer rows.Close()
470475
players := []int{}
471476
for rows.Next() {
472477
var id int
@@ -475,6 +480,9 @@ func TestIntegration_BasicOperators(t *testing.T) {
475480
}
476481
players = append(players, id)
477482
}
483+
if err := rows.Err(); err != nil {
484+
t.Fatal(err)
485+
}
478486

479487
if !reflect.DeepEqual(players, tt.expectedPlayers) {
480488
t.Fatalf("expected %v, got %v", tt.expectedPlayers, players)
@@ -536,7 +544,6 @@ func TestIntegration_NestedJSONB(t *testing.T) {
536544
if err != nil {
537545
t.Fatal(err)
538546
}
539-
defer rows.Close()
540547
players := []int{}
541548
for rows.Next() {
542549
var id int
@@ -545,6 +552,9 @@ func TestIntegration_NestedJSONB(t *testing.T) {
545552
}
546553
players = append(players, id)
547554
}
555+
if err := rows.Err(); err != nil {
556+
t.Fatal(err)
557+
}
548558

549559
if !reflect.DeepEqual(players, tt.expectedPlayers) {
550560
t.Fatalf("%q expected %v, got %v (conditions used: %q)", tt.input, tt.expectedPlayers, players, conditions)
@@ -604,7 +614,6 @@ func TestIntegration_Logic(t *testing.T) {
604614
if err != nil {
605615
t.Fatal(err)
606616
}
607-
defer rows.Close()
608617
players := []int{}
609618
for rows.Next() {
610619
var id int
@@ -613,6 +622,9 @@ func TestIntegration_Logic(t *testing.T) {
613622
}
614623
players = append(players, id)
615624
}
625+
if err := rows.Err(); err != nil {
626+
t.Fatal(err)
627+
}
616628

617629
if !reflect.DeepEqual(players, tt.expectedPlayers) {
618630
t.Fatalf("%q expected %v, got %v (conditions used: %q)", tt.input, tt.expectedPlayers, players, conditions)

integration/setup_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ func setupPQ(t *testing.T) *sql.DB {
2929
return db.PingContext(ctx)
3030
})
3131
t.Cleanup(func() {
32-
db.Close()
32+
db.Close() //nolint:errcheck
3333
})
3434

3535
return db

0 commit comments

Comments
 (0)