prometheus-operator: Get rid of `github.com/pkg/errors` dependency

https://github.com/pkg/errors has been archived and is no longer maintained.

At least 2 options are available:

  • Use the errors package from the standard Go library.
  • Add a depguard rule in the golang-cilint configuration to prevent future use of github.com/pkg/errors.

See also https://github.com/thanos-io/thanos/issues/5176

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Reactions: 1
  • Comments: 15 (15 by maintainers)

Most upvoted comments

Personally I’d be fine with using the standard errors package since the code doesn’t rely on advanced capabilities of github.com/pkg/errors such as stack trace logging.

We could add a linter to catch all occurrences at once