summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArmin Ronacher <armin.ronacher@active-4.com>2016-05-19 19:29:55 +0200
committerArmin Ronacher <armin.ronacher@active-4.com>2016-05-19 19:29:55 +0200
commitecedc08051d67da5762720a3b38a24e1f7b299d3 (patch)
tree2fa4d6691dd64cb5bfba4b9d7c2cd0e8f95e505a
parentc978ba905506622073b668371165fb8a356f9551 (diff)
downloadraven-ecedc08051d67da5762720a3b38a24e1f7b299d3.tar.gz
Automatically activate context on merge
-rw-r--r--CHANGES2
-rw-r--r--raven/context.py4
2 files changed, 5 insertions, 1 deletions
diff --git a/CHANGES b/CHANGES
index d4ad800..c2cc37b 100644
--- a/CHANGES
+++ b/CHANGES
@@ -3,6 +3,8 @@ Version 5.18.0
* Breadcrumbs are now attempted to be deduplicated to catch some common
cases where log messages just spam up the breadcrumbs.
+* Improvements to the public breadcrumbs API and stabilized some.
+* Automatically activate the context on calls to `merge`
Version 5.17.0
--------------
diff --git a/raven/context.py b/raven/context.py
index d27572a..d4a64b9 100644
--- a/raven/context.py
+++ b/raven/context.py
@@ -103,7 +103,9 @@ class Context(local, Mapping, Iterable):
except AttributeError:
pass
- def merge(self, data):
+ def merge(self, data, activate=True):
+ if activate:
+ self.activate()
d = self.data
for key, value in iteritems(data):
if key in ('tags', 'extra'):