Message 147431 - Python tracker
doctests by their very nature tend to overspecify things - that's why actual regression tests should be written with unittest, while doctest is kept for its originally intended purpose of testing examples included in docstrings and other documentation. Still, there's also a reason why IGNORE_EXCEPTION_DETAIL is an available doctest option.