mirror of
https://github.com/Unidata/python-awips.git
synced 2025-02-23 14:57:56 -05:00
Fix returned retVal encoding in SerializableExceptionWrapper
This commit is contained in:
parent
5be5677888
commit
efa301c100
1 changed files with 4 additions and 4 deletions
|
@ -1,4 +1,3 @@
|
|||
|
||||
# File auto-generated against equivalent DynamicSerialize Java class and
|
||||
# modified.
|
||||
#
|
||||
|
@ -7,6 +6,7 @@
|
|||
# Date Ticket# Engineer Description
|
||||
# ------------ ---------- ----------- --------------------------
|
||||
# 2015-02-27 4174 nabowle Output full stacktrace.
|
||||
# 2018-10-05 mjames@ucar Fix returned retVal encoding.
|
||||
#
|
||||
|
||||
class SerializableExceptionWrapper(object):
|
||||
|
@ -23,12 +23,12 @@ class SerializableExceptionWrapper(object):
|
|||
def __repr__(self):
|
||||
if not self.message:
|
||||
self.message = ''
|
||||
retVal = b"" + self.exceptionClass + b" exception thrown: " + self.message + b"\n"
|
||||
retVal = "" + str(self.exceptionClass) + " exception thrown: " + str(self.message) + "\n"
|
||||
for element in self.stackTrace:
|
||||
retVal += b"\tat " + str(element).encode('UTF-8') + b"\n"
|
||||
retVal += "\tat " + str(element) + "\n"
|
||||
|
||||
if self.wrapper:
|
||||
retVal += b"Caused by: " + self.wrapper.__repr__().encode('UTF-8')
|
||||
retVal += "Caused by: " + self.wrapper.__repr__()
|
||||
return str(retVal)
|
||||
|
||||
def getStackTrace(self):
|
||||
|
|
Loading…
Add table
Reference in a new issue