I have a main class and inherited class. I have a decorator function in main class. This following code in base.py.
def functionErrorCase(functionParam): def wrapper(self): try: functionParam(self) except Exception as e: self.InsertError(os.path.basename(__file__), functionParam.__name__) return wrapper Used in all functions in inherited class "__ file __" Command return base.py file name but i want the filename of the used class
How to return the used class file name ?
.__module__attribute, theinspectandtracebackmodule??