def init_rollbar(): """Initialize Rollbar exception logging""" key = environ.get("LOG_KEY") if not (key and app.env == "production"): return rollbar.init(key, root="avwx_api", allow_logging_basic_config=False) got_request_exception.connect(report_exception, app, weak=False)
def init_rollbar(): """ Initialize Rollbar exception logging """ key = environ.get('LOG_KEY') if not (key and app.env == 'production'): return rollbar.init(key, root=path.dirname(path.realpath(__file__)), allow_logging_basic_config=False) got_request_exception.connect(report_exception, app, weak=False)