فهرست منبع

[hadoop] Protect against non defined server_exc attribute in WebHdfsException

This will fix the hiding the real exception in case of problem in
the stats call for example
Romain Rigaux 10 سال پیش
والد
کامیت
40a4e79
1فایلهای تغییر یافته به همراه1 افزوده شده و 0 حذف شده
  1. 1 0
      desktop/libs/hadoop/src/hadoop/fs/exceptions.py

+ 1 - 0
desktop/libs/hadoop/src/hadoop/fs/exceptions.py

@@ -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)