Skip to content

Commit

Permalink
sdk: try to make test_batch_span_processor_reset_timeout a bit less f…
Browse files Browse the repository at this point in the history
…laky (#3937)

If the BatchSpanProcessor has not processed its queue test will fail
with:
 UnboundLocalError: local variable 'after_calls' referenced before assignment
So double the sleep to more than the schedule_delay_millis to give it
more room.

Fix #3936

Co-authored-by: Diego Hurtado <[email protected]>
  • Loading branch information
xrmx and ocelotl authored May 31, 2024
1 parent 83811bf commit 4febd33
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion opentelemetry-sdk/tests/trace/export/test_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,7 @@ def test_batch_span_processor_reset_timeout(self):

# give some time for exporter to loop
# since wait is mocked it should return immediately
time.sleep(0.05)
time.sleep(0.1)
mock_wait_calls = list(mock_wait.mock_calls)

# find the index of the call that processed the singular span
Expand Down

0 comments on commit 4febd33

Please sign in to comment.