etcd-io/etcd

Enable `unexported-return` linter rule

Open

#18.370 aberto em 26 de jul. de 2024

Ver no GitHub
 (24 comments) (0 reactions) (2 assignees)Go (10.352 forks)batch import
area/testinghelp wantedpriority/important-longtermtype/cleanup

Métricas do repositório

Stars
 (51.701 stars)
Métricas de merge de PR
 (Mesclagem média 6d 3h) (71 fundiu PRs em 30d)

Description

What would you like to be added?

There are two remaining linter rules that we haven't enabled but are left as TODO (./tools/.golangci.yaml): exported and unexported-return. The former will have significant changes to exported functions and interfaces. The latter, even though it impacts exported structs, it's for the better (it exposes them without breaking client implementations).

I suggest breaking the pull requests into small tasks like we did on #17578.

The following modules have warnings to be addressed:

  • api - #18645
  • pkg
  • client/pkg
  • client/v3
  • server - #19052
  • tests
    • #19105

Refer to the attached log file with the result from KEEP_GOING_MODULE=true make verify-lint.

Why is this needed?

To improve the quality of the code.

Guia do colaborador