Skip to content

Commit

Permalink
Upgrade golangci-lint
Browse files Browse the repository at this point in the history
1.42 seems to be having some problems with Go 1.18 (see #2649), so let's
just upgrade to latest.  There was one new error, suggesting to use `%q`
rather than `"%s"`, since the former does escapes properly.  It doesn't
really matter for us -- the string should be an identifier -- but it
doesn't hurt.  (Plus it wanted us to upgrade from ioutil, which I did
in #181.)

Test plan: make check
  • Loading branch information
benjaminjkraft committed Mar 22, 2022
1 parent 000f311 commit 74773f3
Show file tree
Hide file tree
Showing 4 changed files with 390 additions and 192 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@ jobs:
- name: Run lint
uses: golangci/golangci-lint-action@v2
with:
version: v1.42 # should match internal/lint/go.mod
version: v1.45 # should match internal/lint/go.mod
2 changes: 1 addition & 1 deletion generate/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -484,7 +484,7 @@ func (typ *goInterfaceType) WriteDefinition(w io.Writer, g *generator) error {
"(see interface doc for possible values).", methodName)
} else {
description = fmt.Sprintf(
`%s returns the interface-field "%s" from its implementation.`,
`%s returns the interface-field %q from its implementation.`,
methodName, sharedField.GraphQLName)
if sharedField.Description != "" {
description = fmt.Sprintf(
Expand Down
4 changes: 2 additions & 2 deletions internal/lint/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/Khan/genqlient/internal/lint

go 1.14
go 1.16

// Should match golangci-lint version in .github/workflows/go.yml
require github.com/golangci/golangci-lint v1.42.0
require github.com/golangci/golangci-lint v1.45.0
Loading

0 comments on commit 74773f3

Please sign in to comment.