mirror of https://github.com/pulumi/pulumi.git
1aae5868af
12461: ci-lint: Upgrade to golangci-lint v1.52 r=abhinav a=abhinav The new release pulls in revive 1.3 which changed its default ruleset. With the new rule set, here are the failures we see: ``` % cat pkg/lint.txt sdk/lint.txt tests/lint.txt | cut -d: -f4 | sort | uniq -c 39 empty-block 11 if-return 67 redefines-builtin-id 5 superfluous-else 589 unused-parameter ``` This PR upgrades pu/pu to the latest release of golangci-lint, and either fixes or excludes linters on a case-by-case basis. Each commit is individually reviewable, and elaborates on the rationale for disabling linter rules, but in short: - unused-parameter: parameter names are useful, and the benefit we'd get from fixing 500+ instances of this is questionable - empty-block: revive has undesirable false positives on this - redefines-builtin-id: we keep this rule except for 'new', which we use frequently in the context of 'old' and 'new' properties. The last commit in this PR fixes all issues not ignored above, and includes the full list of fixed issues in the commit message. Co-authored-by: Abhinav Gupta <abhinav@pulumi.com> |
||
---|---|---|
.. | ||
apitype | ||
constant | ||
diag | ||
display | ||
encoding | ||
env | ||
resource | ||
testing | ||
tokens | ||
tools | ||
util | ||
version | ||
workspace |