From 8c328f93a917699aa9c0b4b83ff35dbdfaa719a7 Mon Sep 17 00:00:00 2001 From: Joe Haines Date: Fri, 1 Sep 2023 10:02:53 +0100 Subject: [PATCH] Create a new context for each Tornado request --- bugsnag/tornado/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bugsnag/tornado/__init__.py b/bugsnag/tornado/__init__.py index 97ee6480..bfb869ca 100644 --- a/bugsnag/tornado/__init__.py +++ b/bugsnag/tornado/__init__.py @@ -3,6 +3,7 @@ from typing import Dict, Any # noqa from urllib.parse import parse_qs, unquote_to_bytes from bugsnag.breadcrumbs import BreadcrumbType +from bugsnag.context import create_new_context from bugsnag.utils import ( is_json_content_type, remove_query_from_url, @@ -130,6 +131,7 @@ def prepare(self): bugsnag.configure().runtime_versions['tornado'] = tornado.version middleware.before_notify(self.add_tornado_request_to_notification) bugsnag.configure()._breadcrumbs.create_copy_for_context() + create_new_context() _auto_leave_breadcrumb( 'http request',