Skip to content

Commit

Permalink
chore: downgrade to go1.19
Browse files Browse the repository at this point in the history
  • Loading branch information
ldez committed Jun 6, 2023
1 parent 3ed42e8 commit a3496e3
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion go.mod
@@ -1,6 +1,6 @@
module github.com/golangci/golangci-lint

go 1.20
go 1.19

require (
4d63.com/gocheckcompilerdirectives v1.2.1
Expand Down
6 changes: 3 additions & 3 deletions netlify.toml
@@ -1,21 +1,21 @@
[context.production.environment]
GO_VERSION = "1.20"
GO_VERSION = "1.19"
NODE_VERSION = "17"
# TODO https://github.com/golangci/golangci-lint/pull/2904#issuecomment-1146870535
# NPM_FLAGS = "--legacy-peer-deps"
# NPM_FLAGS = "--force"
NPM_VERSION = "8.5.5"

[context.deploy-preview.environment]
GO_VERSION = "1.20"
GO_VERSION = "1.19"
NODE_VERSION = "17"
# TODO https://github.com/golangci/golangci-lint/pull/2904#issuecomment-1146870535
# NPM_FLAGS = "--legacy-peer-deps"
# NPM_FLAGS = "--force"
NPM_VERSION = "8.5.5"

[context.branch-deploy.environment]
GO_VERSION = "1.20"
GO_VERSION = "1.19"
NODE_VERSION = "17"
# TODO https://github.com/golangci/golangci-lint/pull/2904#issuecomment-1146870535
# NPM_FLAGS = "--legacy-peer-deps"
Expand Down
7 changes: 4 additions & 3 deletions pkg/lint/lintersdb/custom_linters.go
@@ -1,7 +1,6 @@
package lintersdb

import (
"errors"
"fmt"
"path/filepath"
"plugin"
Expand Down Expand Up @@ -98,7 +97,8 @@ func (m *Manager) lookupPlugin(plug *plugin.Plugin, settings any) ([]*analysis.A
if err != nil {
analyzers, errP := m.lookupAnalyzerPlugin(plug)
if err != nil {
return nil, errors.Join(err, errP)
// TODO(ldez): use `errors.Join` when we will upgrade to go1.20.
return nil, fmt.Errorf("%s: %w", err, errP)
}

return analyzers, nil
Expand All @@ -119,7 +119,8 @@ func (m *Manager) lookupAnalyzerPlugin(plug *plugin.Plugin) ([]*analysis.Analyze
return nil, err
}

m.log.Warnf("plugin: 'AnalyzerPlugin' plugins are deprecated, please the new plugin signature: https://golangci-lint.run/contributing/new-linters/#create-a-plugin")
m.log.Warnf("plugin: 'AnalyzerPlugin' plugins are deprecated, please the new plugin signature:" +
"https://golangci-lint.run/contributing/new-linters/#create-a-plugin")

analyzerPlugin, ok := symbol.(AnalyzerPlugin)
if !ok {
Expand Down

0 comments on commit a3496e3

Please sign in to comment.