From 0c1c699832c62950d7ac1e83f3b8fc24969de833 Mon Sep 17 00:00:00 2001 From: rhilfers Date: Tue, 28 Jan 2020 20:13:29 -0800 Subject: [PATCH] Fixed common tags leaking state between spans (#9) * fix bug where state is leaked between spans when using common tags feature * fix linting issue --- haystack/tracer.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/haystack/tracer.py b/haystack/tracer.py index 901afa6..56b1ab5 100644 --- a/haystack/tracer.py +++ b/haystack/tracer.py @@ -105,7 +105,8 @@ def start_span(self, # Set common tags if self._common_tags: - tags = {**self._common_tags, **tags} if tags else self._common_tags + tags = {**self._common_tags, **tags} if tags else \ + self._common_tags.copy() return Span(self, operation_name=operation_name,