I have written a function f(x) that either returns a dictionary or an error message.
def myfunc():
try:
return dictionary
except BaseException as e:
return e
return_value = myfunc()
if return_value a dictionary:
do this
else:
do that
I need to detect the type of return in another function f(y) which calls f(x).
How do I do that?
thanks in advance