-
Notifications
You must be signed in to change notification settings - Fork 52
Chore/no issue update go run go fix #1334
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
cgoetz-inovex
wants to merge
7
commits into
main
Choose a base branch
from
chore/NO-ISSUE_update-go-run-go-fix
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
564a8ad
chore(go) update to go 1.26
cgoetz-inovex e809dc9
chore(go) run `go fix ./...`
cgoetz-inovex 9e90485
chore(deps) update golangci-lint version
cgoetz-inovex f6d8890
fix(deps) use correct golangci-lint url
cgoetz-inovex e447cda
fix(deps) migrate golangci-lint config
cgoetz-inovex 573a474
fix(lint) configure linter after update, fix linting issues
cgoetz-inovex 027a5d3
fix(lint) ignore false positive
cgoetz-inovex File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,100 +1,117 @@ | ||
| # This file contains all available configuration options | ||
| # with their default values. | ||
|
|
||
| version: "2" | ||
| # options for analysis running | ||
| run: | ||
| # default concurrency is a available CPU number | ||
| concurrency: 4 | ||
|
|
||
| # timeout for analysis, e.g. 30s, 5m, default is 1m | ||
| timeout: 5m | ||
| linters-settings: | ||
| goimports: | ||
| # put imports beginning with prefix after 3rd-party packages; | ||
| # it's a comma-separated list of prefixes | ||
| local-prefixes: github.com/freiheit-com/nmww | ||
| depguard: | ||
| rules: | ||
| main: | ||
| list-mode: lax # Everything is allowed unless it is denied | ||
| deny: | ||
| - pkg: "github.com/stretchr/testify" | ||
| desc: Do not use a testing framework | ||
| misspell: | ||
| # Correct spellings using locale preferences for US or UK. | ||
| # Default is to use a neutral variety of English. | ||
| # Setting locale to US will correct the British spelling of 'colour' to 'color'. | ||
| locale: US | ||
| golint: | ||
| min-confidence: 0.8 | ||
| gosec: | ||
| excludes: | ||
| # Suppressions: (see https://github.com/securego/gosec#available-rules for details) | ||
| - G104 # "Audit errors not checked" -> which we don't need and is a badly implemented version of errcheck | ||
| - G102 # "Bind to all interfaces" -> since this is normal in k8s | ||
| - G304 # "File path provided as taint input" -> too many false positives | ||
| - G307 # "Deferring unsafe method "Close" on type "io.ReadCloser" -> false positive when calling defer resp.Body.Close() | ||
| nakedret: | ||
| max-func-lines: 0 | ||
| revive: | ||
| ignore-generated-header: true | ||
| severity: error | ||
| # https://github.com/mgechev/revive | ||
| rules: | ||
| - name: errorf | ||
| - name: context-as-argument | ||
| - name: error-return | ||
| - name: increment-decrement | ||
| - name: indent-error-flow | ||
| - name: superfluous-else | ||
| - name: unused-parameter | ||
| - name: unreachable-code | ||
| - name: atomic | ||
| - name: empty-lines | ||
| - name: early-return | ||
| gocritic: | ||
| enabled-tags: | ||
| - performance | ||
| - style | ||
| - experimental | ||
| disabled-checks: | ||
| - wrapperFunc | ||
| - typeDefFirst | ||
| - ifElseChain | ||
| - dupImport # https://github.com/go-critic/go-critic/issues/845 | ||
| linters: | ||
| enable: | ||
| # https://golangci-lint.run/usage/linters/ | ||
| # default linters | ||
| - gosimple | ||
| - govet | ||
| - ineffassign | ||
| - staticcheck | ||
| - typecheck | ||
| - unused | ||
| # additional linters | ||
| - bodyclose | ||
| - depguard | ||
| - errorlint | ||
| - forcetypeassert | ||
| - gochecknoinits | ||
| - gocritic | ||
| - gofmt | ||
| - goimports | ||
| - gosec | ||
| - misspell | ||
| - nakedret | ||
| - revive | ||
| - depguard | ||
| - bodyclose | ||
| - sqlclosecheck | ||
| - wastedassign | ||
| - forcetypeassert | ||
| - errcheck | ||
| disable: | ||
| - noctx # false positive: finds errors with http.NewRequest that dont make sense | ||
| - unparam # false positives | ||
| issues: | ||
| exclude-use-default: false | ||
| # disable deprecation errors while we switch over to the SDK structure with multi API version support | ||
| exclude-rules: | ||
| - linters: | ||
| - staticcheck | ||
| text: "SA1019:" | ||
| settings: | ||
| depguard: | ||
| rules: | ||
| main: | ||
| list-mode: lax # Everything is allowed unless it is denied | ||
| deny: | ||
| - pkg: github.com/stretchr/testify | ||
| desc: Do not use a testing framework | ||
| gocritic: | ||
| disabled-checks: | ||
| - wrapperFunc | ||
| - typeDefFirst | ||
| - ifElseChain | ||
| - dupImport # https://github.com/go-critic/go-critic/issues/845 | ||
| enabled-tags: | ||
| - performance | ||
| - style | ||
| - experimental | ||
| gosec: | ||
| excludes: | ||
| # Suppressions: (see https://github.com/securego/gosec#available-rules for details) | ||
| - G101 # "Look for hardcoded credentials" -> a lot of false positives in descriptions for resources like mariadb/credential | ||
| - G104 # "Audit errors not checked" -> which we don't need and is a badly implemented version of errcheck | ||
| - G102 # "Bind to all interfaces" -> since this is normal in k8s | ||
| - G304 # "File path provided as taint input" -> too many false positives | ||
| - G307 # "Deferring unsafe method "Close" on type "io.ReadCloser" -> false positive when calling defer resp.Body.Close() | ||
| misspell: | ||
| # Correct spellings using locale preferences for US or UK. | ||
| # Default is to use a neutral variety of English. | ||
| # Setting locale to US will correct the British spelling of 'colour' to 'color'. | ||
| locale: US | ||
| nakedret: | ||
| max-func-lines: 0 | ||
| revive: | ||
| severity: error | ||
| # https://github.com/mgechev/revive | ||
| rules: | ||
| - name: errorf | ||
| - name: context-as-argument | ||
| - name: error-return | ||
| - name: increment-decrement | ||
| - name: indent-error-flow | ||
| - name: superfluous-else | ||
| - name: unused-parameter | ||
| - name: unreachable-code | ||
| - name: atomic | ||
| - name: empty-lines | ||
| - name: early-return | ||
| staticcheck: | ||
| checks: | ||
| # default from https://golangci-lint.run/docs/linters/configuration/#staticcheck | ||
| - all | ||
| - "-ST1000" | ||
| - "-ST1003" | ||
| - "-ST1016" | ||
| - "-ST1020" | ||
| - "-ST1021" | ||
| - "-ST1022" | ||
| # customizations | ||
| - "-SA1019" # disable deprecation errors while we switch over to the SDK structure with multi API version support | ||
| - "-QF1001" # disable 'could apply De Morgan's law': readability of boolean expressions is subjective and should be decided on a case-by-case basis | ||
| - "-QF1012" # disable 'use fmt.Fprintf instead' Fprintf returns bytes written and an error, which we'd have to handle/ignore to appease some other linter | ||
| exclusions: | ||
| generated: lax | ||
| rules: | ||
| - linters: | ||
| - gocritic | ||
| text: 'dupOption' | ||
| path: _acc_test\.go | ||
| paths: | ||
| - third_party$ | ||
| - builtin$ | ||
| - examples$ | ||
| formatters: | ||
| enable: | ||
| - gofmt | ||
| - goimports | ||
| settings: | ||
| goimports: | ||
| # put imports beginning with prefix after 3rd-party packages; | ||
| # it's a comma-separated list of prefixes | ||
| local-prefixes: | ||
| - github.com/freiheit-com/nmww | ||
| exclusions: | ||
| generated: lax | ||
| paths: | ||
| - third_party$ | ||
| - builtin$ | ||
| - examples$ | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this looks like a copy paste error to me