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

chore(lint): add nilnil, nilerr and exportloopref linters #2072

Merged
merged 9 commits into from
Dec 9, 2021

Conversation

qdm12
Copy link
Contributor

@qdm12 qdm12 commented Nov 26, 2021

Changes

  • Add nilnil, nilerrandexportloopref` linters
  • Fix lint errors whenever possible or add //nolint comments when not applicable

Tests

golangci-lint run

And CI to pass

Issues

Primary Reviewer

@codecov
Copy link

codecov bot commented Nov 26, 2021

Codecov Report

Merging #2072 (f2a7d9e) into development (6f9f730) will decrease coverage by 0.01%.
The diff coverage is 52.77%.

Impacted file tree graph

@@               Coverage Diff               @@
##           development    #2072      +/-   ##
===============================================
- Coverage        61.25%   61.23%   -0.02%     
===============================================
  Files              203      203              
  Lines            27344    27341       -3     
===============================================
- Hits             16749    16743       -6     
- Misses            8717     8720       +3     
  Partials          1878     1878              
Flag Coverage Δ
unit-tests 61.23% <52.77%> (-0.02%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
dot/state/grandpa.go 40.50% <0.00%> (+0.40%) ⬆️
lib/genesis/test_utils.go 0.00% <0.00%> (ø)
lib/grandpa/message_handler.go 64.42% <0.00%> (ø)
lib/runtime/life/resolver.go 61.70% <0.00%> (ø)
lib/runtime/wasmer/imports.go 48.66% <0.00%> (-0.26%) ⬇️
dot/sync/chain_sync.go 55.08% <33.33%> (-0.15%) ⬇️
lib/babe/epoch.go 60.16% <71.42%> (-0.33%) ⬇️
dot/rpc/modules/state.go 95.41% <100.00%> (+0.02%) ⬆️
dot/sync/bootstrap_syncer.go 74.07% <100.00%> (ø)
dot/sync/tip_syncer.go 82.75% <100.00%> (ø)
... and 4 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6f9f730...f2a7d9e. Read the comment docs.

dot/sync/bootstrap_syncer.go Outdated Show resolved Hide resolved
dot/sync/bootstrap_syncer.go Outdated Show resolved Hide resolved
lib/babe/errors.go Outdated Show resolved Hide resolved
@qdm12 qdm12 changed the title chore(lint): add nilnil, nilerr and exportloopref` linters chore(lint): add nilnil, nilerr and exportloopref linters Nov 27, 2021
dot/state/grandpa.go Show resolved Hide resolved
dot/sync/bootstrap_syncer.go Outdated Show resolved Hide resolved
lib/genesis/test_utils.go Show resolved Hide resolved
lib/genesis/test_utils.go Show resolved Hide resolved
dot/state/grandpa.go Show resolved Hide resolved
lib/common/types/result.go Show resolved Hide resolved
tests/utils/gossamer_utils.go Show resolved Hide resolved
Copy link
Contributor

@kishansagathiya kishansagathiya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

@qdm12 qdm12 merged commit 1e74231 into development Dec 9, 2021
@qdm12 qdm12 deleted the qdm12-lint-new-linters branch December 9, 2021 15:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants