All

Creating and Using Custom Error Types

Episode 17

We explore the error interface (https://godoc.org/builtin#error) more closely and explain how and why to create custom error types that you can pass wherever an error is expected.

We also talk about some best practices in exposing and describing your custom types inside of your libraries and packages.

Sponsor

Sponsored by Minio - Minio is an open source object storage server, compatible with Amazon S3 and written in Go. It is light enough to be bundled along the application stack, similar to Node.js and MongoDB. Check them out at https://github.com/minio or hangout with them at https://gitter.im/minio/minio

Check out the example code on Github.


If you enjoyed this screencast, please consider becoming a backer and supporting Go in 5 Minutes. Cool stickers and more await you!