diff --git a/skywalking/plugins/sw_tornado.py b/skywalking/plugins/sw_tornado.py index 00d9ca52..b03a12b9 100644 --- a/skywalking/plugins/sw_tornado.py +++ b/skywalking/plugins/sw_tornado.py @@ -64,9 +64,9 @@ async def _sw_get_response(self, *args, **kwargs): span.tag( Tag(key=tags.HttpUrl, val='{}://{}{}'.format(request.protocol, request.host, request.path))) result = old_execute(self, *args, **kwargs) - span.tag(Tag(key=tags.HttpStatus, val=self._status_code, overridable=True)) if isawaitable(result): result = await result + span.tag(Tag(key=tags.HttpStatus, val=self._status_code, overridable=True)) if self._status_code >= 400: span.error_occurred = True return result