|
def get_sourceline(obj): |
|
try: |
|
s, n = inspect.getsourcelines(obj) |
|
except: |
|
try: |
|
# this handles `tornado` case we need a better |
|
# way to get to the wrapped function. |
|
# This is a temporary solution |
|
s, n = inspect.getsourcelines(obj.orig_method) |
|
except: |
|
return "*" |
Those bare except statements are also extremely broad.