This will fix the hiding the real exception in case of problem in the stats call for example
@@ -35,6 +35,7 @@ class PermissionDeniedException(StructuredException):
class WebHdfsException(RestException):
def __init__(self, error):
RestException.__init__(self, error)
+ self.server_exc = None
try:
json_body = json.loads(self._message)