Add ErrorStack method to the error type

Adds a method to write out the error stack so other packages can use interface checking rather than a hard project dependency in order to get the ErrorStack for an error.