Skip to content

Commit

Permalink
Pin linter version and fix nolintlint/gosec fix (#174)
Browse files Browse the repository at this point in the history
* Pin linter version

Same as fortio/workflows#67
(need to figure cross org share actually rather than copy-pasta)

* Fix the nolintlint now that gosec is fixed and the fix in linters 1.60.3

* Update .github/workflows/gochecks.yml
  • Loading branch information
ldemailly authored Aug 23, 2024
1 parent 7765b86 commit 1ea18e9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .github/workflows/gochecks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ jobs:
run: curl -fsS -o .golangci.yml https://raw.githubusercontent.com/fortio/workflows/main/golangci.yml
- name: Run golangci-lint
uses: golangci/golangci-lint-action@aaa42aa0628b4ae2578232a66b541047968fac86 # pin@v6
with:
version: v1.60.3
- name: Run tests
run: |
go version
Expand Down
2 changes: 1 addition & 1 deletion eval/eval.go
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ func evalIndexExpression(left, index object.Object) object.Object {
if idx < 0 || idx >= int64(len(str)) {
return object.NULL
}
return object.Integer{Value: int64(str[idx])} //nolint:gosec // https://github.com/securego/gosec/issues/1185
return object.Integer{Value: int64(str[idx])}
case left.Type() == object.ARRAY && idxOrZero.Type() == object.INTEGER:
return evalArrayIndexExpression(left, idxOrZero)
case left.Type() == object.MAP:
Expand Down

0 comments on commit 1ea18e9

Please sign in to comment.