File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ def run(self):
3636 def report_spans (self ):
3737 """ Periodically report the queued spans """
3838 while 1 :
39- if self .sensor .agent .can_send () and self .queue .qsize :
39+ if self .sensor .agent .can_send () and self .queue .qsize () > 0 :
4040 url = self .sensor .agent .make_url (a .AGENT_TRACES_URL )
4141 self .sensor .agent .request (url , "POST" , self .queued_spans ())
4242 time .sleep (1 )
@@ -66,7 +66,7 @@ def record_span(self, span):
6666 Convert the passed BasicSpan into an InstanaSpan and
6767 add it to the span queue
6868 """
69- if self .sensor .agent .can_send () or os . environ [ "INSTANA_TEST" ] :
69+ if self .sensor .agent .can_send () or "INSTANA_TEST" in os . environ :
7070 instana_span = None
7171
7272 if span .operation_name in self .registered_spans :
You can’t perform that action at this time.
0 commit comments