honeybansal23/nextAnalytics
0
1import bugsnag2from reddit.load_env import bugsnag_token3 4class CustomLogger:5 def __init__(self):6 bugsnag.configure(7 api_key=bugsnag_token,8 project_root="../",9 )10 11 def log(self, message: str):12 try:13 bugsnag.notify(Exception('Error'),14 context=message,15 )16 except Exception as e:17 bugsnag.notify(Exception('Self-Error'),18 context=e,19 )20 21app_logger = CustomLogger()