In this excellent talk, Francesc Campoy recommends to always return the error interface for errors, rather than specific examples. This helps avoid tricky bugs related to the "non-nil interface can contain a boxed nil" pattern. We return *ProblemDetails in a few places, intending to more clearly document that those functions always return a *ProblemDetails, not some other error. However, we should probably change that.
Direct link to most relevant bit: https://youtu.be/ynoY2xz-F8s?t=699