1- run :
2- timeout : 10m
1+ linters :
2+ enable-all : true
3+ disable :
4+ - gomnd # deprecated
5+ - cyclop # duplicate of gocyclo
6+ - sqlclosecheck # not relevant (SQL)
7+ - rowserrcheck # not relevant (SQL)
8+ - execinquery # not relevant (SQL)
9+ - lll
10+ - gosec
11+ - dupl # not relevant
12+ - prealloc # too many false-positive
13+ - bodyclose # too many false-positive
14+ - mnd
15+ - testpackage # not relevant
16+ - tparallel # not relevant
17+ - paralleltest # not relevant
18+ - nestif # too many false-positive
19+ - wrapcheck
20+ - err113 # not relevant
21+ - nlreturn # not relevant
22+ - wsl # not relevant
23+ - exhaustive # not relevant
24+ - exhaustruct # not relevant
25+ - makezero # not relevant
26+ - forbidigo
27+ - varnamelen # not relevant
28+ - nilnil # not relevant
29+ - ireturn # not relevant
30+ - contextcheck # too many false-positive
31+ - tenv # we already have a test "framework" to handle env vars
32+ - noctx
33+ - forcetypeassert
34+ - tagliatelle
35+ - errname
36+ - errchkjson
37+ - nonamedreturns
38+ - musttag # false-positive https://github.com/junk1tm/musttag/issues/17
39+ - gosmopolitan # not relevant
40+ - exportloopref # Useless with go1.22
41+ - canonicalheader # Can create side effects in the context of API clients
42+ - usestdlibvars # false-positive https://github.com/sashamelentyev/usestdlibvars/issues/96
343
444linters-settings :
545 govet :
@@ -96,50 +136,18 @@ linters-settings:
96136 sprintf1 : true
97137 strconcat : false
98138
99- linters :
100- enable-all : true
101- disable :
102- - gomnd # deprecated
103- - cyclop # duplicate of gocyclo
104- - sqlclosecheck # not relevant (SQL)
105- - rowserrcheck # not relevant (SQL)
106- - execinquery # not relevant (SQL)
107- - lll
108- - gosec
109- - dupl # not relevant
110- - prealloc # too many false-positive
111- - bodyclose # too many false-positive
112- - mnd
113- - testpackage # not relevant
114- - tparallel # not relevant
115- - paralleltest # not relevant
116- - nestif # too many false-positive
117- - wrapcheck
118- - err113 # not relevant
119- - nlreturn # not relevant
120- - wsl # not relevant
121- - exhaustive # not relevant
122- - exhaustruct # not relevant
123- - makezero # not relevant
124- - forbidigo
125- - varnamelen # not relevant
126- - nilnil # not relevant
127- - ireturn # not relevant
128- - contextcheck # too many false-positive
129- - tenv # we already have a test "framework" to handle env vars
130- - noctx
131- - forcetypeassert
132- - tagliatelle
133- - errname
134- - errchkjson
135- - nonamedreturns
136- - musttag # false-positive https://github.com/junk1tm/musttag/issues/17
137- - gosmopolitan # not relevant
138- - exportloopref # Useless with go1.22
139- - canonicalheader # Can create side effects in the context of API clients
140- - usestdlibvars # false-positive https://github.com/sashamelentyev/usestdlibvars/issues/96
139+ run :
140+ timeout : 10m
141+
142+ output :
143+ show-stats : true
144+ sort-results : true
145+ sort-order :
146+ - linter
147+ - file
141148
142149issues :
150+ exclude-generated : strict
143151 exclude-use-default : false
144152 max-issues-per-linter : 0
145153 max-same-issues : 0
@@ -160,86 +168,96 @@ issues:
160168 - path : providers/dns/dns_providers.go
161169 linters :
162170 - gocyclo
163- - path : providers/dns/gcloud/googlecloud_test.go
164- text : ' string `(lego\.wtf|manhattan)` has (\d+) occurrences, make it a constant'
165- - path : providers/dns/zoneee/zoneee_test.go
166- text : ' string `(bar|foo)` has (\d+) occurrences, make it a constant'
167171 - path : certcrypto/crypto.go
168172 text : ' (tlsFeatureExtensionOID|ocspMustStapleFeature) is a global variable'
173+ linters :
174+ - gochecknoglobals
169175 - path : challenge/dns01/nameserver.go
170176 text : ' (defaultNameservers|recursiveNameservers|fqdnSoaCache|muFqdnSoaCache) is a global variable'
177+ linters :
178+ - gochecknoglobals
171179 - path : challenge/dns01/nameserver_.+.go
172180 text : ' dnsTimeout is a global variable'
181+ linters :
182+ - gochecknoglobals
173183 - path : challenge/dns01/nameserver_test.go
174184 text : ' findXByFqdnTestCases is a global variable'
185+ linters :
186+ - gochecknoglobals
175187 - path : challenge/http01/domain_matcher.go
176188 text : ' string `Host` has \d occurrences, make it a constant'
189+ linters :
190+ - goconst
177191 - path : challenge/http01/domain_matcher.go
178192 text : ' cyclomatic complexity \d+ of func `parseForwardedHeader` is high'
193+ linters :
194+ - gocyclo
179195 - path : challenge/http01/domain_matcher.go
180196 text : " Function 'parseForwardedHeader' has too many statements"
197+ linters :
198+ - funlen
181199 - path : challenge/tlsalpn01/tls_alpn_challenge.go
182200 text : ' idPeAcmeIdentifierV1 is a global variable'
201+ linters :
202+ - gochecknoglobals
183203 - path : log/logger.go
184204 text : ' Logger is a global variable'
205+ linters :
206+ - gochecknoglobals
185207 - path : ' e2e/(dnschallenge/)?[\d\w]+_test.go'
186208 text : load is a global variable
209+ linters :
210+ - gochecknoglobals
187211 - path : ' providers/dns/([\d\w]+/)*[\d\w]+_test.go'
188212 text : ' envTest is a global variable'
213+ linters :
214+ - gochecknoglobals
189215 - path : ' providers/http/([\d\w]+/)*[\d\w]+_test.go'
190216 text : ' envTest is a global variable'
217+ linters :
218+ - gochecknoglobals
191219 - path : providers/dns/namecheap/namecheap_test.go
192220 text : ' testCases is a global variable'
221+ linters :
222+ - gochecknoglobals
193223 - path : providers/dns/acmedns/acmedns_test.go
194224 text : ' egTestAccount is a global variable'
225+ linters :
226+ - gochecknoglobals
195227 - path : providers/http/memcached/memcached_test.go
196228 text : ' memcachedHosts is a global variable'
197- - path : providers/dns/sakuracloud/client_test.go
198- text : ' cyclomatic complexity 13 of func `(TestDNSProvider_cleanupTXTRecord_concurrent|TestDNSProvider_addTXTRecord_concurrent)` is high'
199- - path : providers/dns/dns_providers.go
200- text : " Function 'NewDNSChallengeProviderByName' has too many statements"
201- - path : cmd/flags.go
202- text : " Function 'CreateFlags' is too long"
203- - path : certificate/certificates.go
204- text : " Function 'GetOCSP' is too long"
205- - path : providers/dns/otc/client.go
206- text : " Function 'loginRequest' is too long"
207- - path : providers/dns/gandi/gandi.go
208- text : " Function 'Present' is too long"
229+ linters :
230+ - gochecknoglobals
209231 - path : cmd/zz_gen_cmd_dnshelp.go
210232 linters :
211233 - gocyclo
212234 - funlen
213235 - path : providers/dns/checkdomain/internal/types.go
214236 text : ' `payed` is a misspelling of `paid`'
215- - path : providers/dns/namecheap/namecheap_test.go
216- text : ' cognitive complexity (\d+) of func `TestDNSProvider_getHosts` is high '
237+ linters :
238+ - misspell
217239 - path : platform/tester/env_test.go
218240 linters :
219241 - thelper
220242 - path : providers/dns/oraclecloud/oraclecloud_test.go
221243 text : ' SA1019: x509.EncryptPEMBlock has been deprecated since Go 1.16'
222- - path : challenge/http01/domain_matcher.go
223- text : ' yodaStyleExpr'
224- - path : providers/dns/dns_providers.go
225- text : ' Function name: NewDNSChallengeProviderByName,'
244+ linters :
245+ - staticcheck
226246 - path : providers/dns/sakuracloud/wrapper.go
227247 text : ' mu is a global variable'
228- - path : providers/dns/hosttech/internal/client_test.go
229- text : ' Duplicate words \(0\) found '
248+ linters :
249+ - gochecknoglobals
230250 - path : cmd/cmd_renew.go
231251 text : ' cyclomatic complexity \d+ of func `(renewForDomains|renewForCSR)` is high'
252+ linters :
253+ - gocyclo
232254 - path : providers/dns/cpanel/cpanel.go
233255 text : ' cyclomatic complexity 13 of func `\(\*DNSProvider\)\.CleanUp` is high'
256+ linters :
257+ - gocyclo
234258
235259 # Those elements have been replaced by non-exposed structures.
236260 - path : providers/dns/linode/linode_test.go
237261 linters :
238262 - staticcheck
239263 text : " SA1019: linodego\\ .(DomainsPagedResponse|DomainRecordsPagedResponse) is deprecated"
240-
241- output :
242- sort-results : true
243- sort-order :
244- - linter
245- - file
0 commit comments