You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
go-spew can panic when trying to diff certain types of values, there are
open issues about this on their GitHub repository.
go-spew is unfortunately unmaintained, we cannot expect a fix any time
soon. Also, because of go-spew's design, there are multiple causes for
a panic, and fixing all of them would be a huge undertaking.
We already return an empty diff when the types are not comparable, or
when the values are not from types that can be easily diffed by go-spew.
Let's hide the panic by recovering from it, and returning an empty diff
instead. This is not ideal, but at least it prevents the entire program from
crashing. The expected/actual values will still be printed, just without
the diff.
0 commit comments