Open mkatychev opened 4 years ago
Just a note that while I would also like this behavior, it changes the output of the library and thus may break any code depending on the output to be stable. As a result, I doubt we will end up accepting it at this time unless we want to consider a major rev bump. Pinging @mitchellh for opinions.
Testing for 1 error in unit tests and emitting only one error makes the
\n\t*
prepend impractical and noisy.There should be no need to do any multiple error logic until more than one error is present.
When
multierror.Error.Error()
is called withlen(multierror.Error.Errors) == 1
, the formatting should be deferred (gracefully decompose) to the one and only error present:multierror.Error[0].Error()