How to throw in python error

Hi,

my workflow is here

My Python code is a simple code for handling exceptions.

test.py ---------------------

class TestError(Exception):
def init(self, value):
self.value = value
def str(self):
return self.value

def test(a):
try:
print(a)
b=a+“HI”
if not a ==“22”:
raise TestError(‘ErrorError.’)
except Exception as e:
print(e)
print(“End22”)
return e
print(“End”)


i wanna return exception message.
but output message is image .

how can i get message??

Thanks,

I tried to use ‘’ but the error occurred as below and I couldn’t use it.