Skip to content

refactor: use std errors following errorlint rules - #3272

Open
mmorel-35 wants to merge 1 commit into
moby:masterfrom
mmorel-35:errors
Open

refactor: use std errors following errorlint rules#3272
mmorel-35 wants to merge 1 commit into
moby:masterfrom
mmorel-35:errors

Conversation

@mmorel-35

Copy link
Copy Markdown

- What I did

use standard errors instead of github.com/pkg/errors along with activation of errorlint linter and errorf, unnecessary-format and use-errors-new rules from revive

- How I did it

Replace github.com/pkg/errors.Wrap[f](err, "...") with fmt.Errorf("...: %w", err) same logic goes for error comparisons and type checking. Everything was done manually with only the help of golangci-lint

- How to test it

- Description for the changelog

Fixes #3203

Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
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.

1 participant