wag-managment-api-service-v.../ApiLibrary/common/line_number.py

6 lines
186 B
Python

def get_line_number_for_error():
from inspect import currentframe, getframeinfo
frameinfo = getframeinfo(currentframe())
return f"{frameinfo.filename} | {frameinfo.lineno}"