Skip to content
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

Enable revive linter rule #2344

Open
1 task done
ademidoff opened this issue Jul 3, 2023 · 2 comments
Open
1 task done

Enable revive linter rule #2344

ademidoff opened this issue Jul 3, 2023 · 2 comments
Assignees

Comments

@ademidoff
Copy link
Member

Description

Ref: #1541
We'd like to enable revive linter rule.

Suggested solution

  • evaluate if we can afford to enable the rule
  • if yes, fix all linter error to make tests pass
  • if not, disable the rule and leave a comment explaining why (subject to review by the dev team)

Additional context

The rule can be enabled by simply removing this line.
You can check similar PRs to see how we enabled some other rules (ref: #1541)

Code of Conduct

  • I agree to follow this project's Code of Conduct
@vishwas-sharma2480
Copy link
Contributor

Hi @BupycHuk I have a doubt these alerts are by revive linter rule which is asking to change variable name
managed/utils/validators/validators.go:28:2: time-naming: var MetricsResolutionMin is of type time.Duration; don't use unit-specific suffix "Min" (revive)
MetricsResolutionMin = time.Second
^
managed/utils/validators/validators.go:32:2: time-naming: var STTCheckIntervalMin is of type time.Duration; don't use unit-specific suffix "Min" (revive)
STTCheckIntervalMin = time.Second
^
managed/utils/validators/validators.go:36:2: time-naming: var DataRetentionMin is of type time.Duration; don't use unit-specific suffix "Min" (revive)

should i change these or let it be there are simiillar alerts like this as well

@BupycHuk
Copy link
Member

Hi @vishwas-sharma2480 , let's add nolint comment for them.

@artemgavrilov artemgavrilov removed their assignment Jan 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants