Currently errors in attest.Ok() are printed using t.Printf("error: %v", err). This proposal is to change that to t.Printf("error: %+v", err).
The rationale is, there are some 3rd party error libraries that add stack traces to their errors, for those they mostly use the + flag when you want to print the error and the trace.
This issue is not about encouraging people to use error packages with stack traces, it is about improving the experience of those who do. Additionally people who do not use stack traces are not negatively affected by the change and finally it is not a huge change to the attest library.
Currently errors in
attest.Ok()
are printed usingt.Printf("error: %v", err)
. This proposal is to change that tot.Printf("error: %+v", err)
. The rationale is, there are some 3rd party error libraries that add stack traces to their errors, for those they mostly use the+
flag when you want to print the error and the trace.Examples:
pkg/errors
; https://github.com/pkg/errors/blob/5dd12d0cfe7f152f80558d591504ce685299311e/errors.go#L127-L132cockroachdb/errors
; https://github.com/cockroachdb/errors/blob/c1cc1919cf999fb018fcd038852e969e3d5631cc/withstack/stack.go#L29-L36This issue is not about encouraging people to use error packages with stack traces, it is about improving the experience of those who do. Additionally people who do not use stack traces are not negatively affected by the change and finally it is not a huge change to the attest library.