DEV Community

Jonathan Hall
Jonathan Hall

Posted on

What's the proper way to wrap errors in Go?

errors.New()? fmt.Errorf()? errors.Errorf()? errors.Wrapf()? Which should you use?

In this video, I dive into the history of the various ways to wrap errors in Go, and describe which method(s) you should be using now.

Top comments (0)