lightning: Fix lints for lightning (#766)#989
Conversation
|
[REVIEW NOTIFICATION] This pull request has not been approved. To complete the pull request process, please ask the reviewers in the list to review by filling The full list of commands accepted by this bot can be found here. DetailsReviewer can indicate their review by writing |
|
@ti-srebot: PR needs rebase. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
adc7582 to
21cd427
Compare
|
/cherry-pick-invite |
|
@YuJuncen please accept the invitation then you can push to the cherry-pick pull requests. |
cherry-pick #766 to release-5.0
You can switch your code base to this Pull Request by using git-extras:
# In br repo: git pr https://github.com/pingcap/br/pull/989After apply modifications, you can push your change to this PR via:
What problem does this PR solve?
CI for
tidb-lightningdoesn't include lints, after merged into this repository, we hope it can pass the CI tests too.What is changed and how it works?
Refactoring following what the linter says.
NOTEs
Those linters are disabled:
Standard
errorsuseserr.Unwrap()to get cause of errors. Butpingcap/errorsuseserr.Cause()anderrors.Unwrap(err). If we follow this linter, usingerrors.Isto check error class, causes of errors would be omitted.errors.Trace(err), which is tricky, and in someway not really wrapped those errors. Maybe we need farther refactoring for error returning.Check List
Tests
Code changes
Release Note