ainsleyclark / errors

🫠 A drop-in replacement for Go errors, with some added sugar! Error handling in Go made easy with codes, messages and more. Failure is your domain!
MIT License
14 stars 1 forks source link

RFC7807 #5

Open ptman opened 1 year ago

ptman commented 1 year ago

Since you seem to serialize the error as JSON , please take a look at RFC7807 for standardizing JSON errors. https://paul.totterman.name/posts/rfc7807/

ainsleyclark commented 1 year ago

Hi there, This is a great RFC but I'm slightly concerned about backwards compatibility.

ptman commented 1 year ago

You can keep the fields from both. But just a thought

ptman commented 1 week ago

And there has been a new RFC that obsoletes the old: https://datatracker.ietf.org/doc/html/rfc9457

ainsleyclark commented 1 week ago

Happy to accept a PR for this.