From 1f82ad8c563f57ac25bb513d13b7a47fb58c85e9 Mon Sep 17 00:00:00 2001 From: Uma Annamalai Date: Thu, 11 Nov 2021 10:30:20 -0800 Subject: [PATCH] Add check for txn settings. (#425) --- newrelic/api/database_trace.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/newrelic/api/database_trace.py b/newrelic/api/database_trace.py index b17d4036df..f481a20a7f 100644 --- a/newrelic/api/database_trace.py +++ b/newrelic/api/database_trace.py @@ -137,6 +137,10 @@ def finalize_data(self, transaction, exc=None, value=None, tb=None): database_name = None settings = transaction.settings + + if not settings: + return + tt = settings.transaction_tracer agent_limits = settings.agent_limits ds_tracer = settings.datastore_tracer