Skip to content
This repository was archived by the owner on Sep 17, 2025. It is now read-only.

Commit 329b214

Browse files
authored
Use chain.from_iterable in span.py (#911)
1 parent dea0794 commit 329b214

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

opencensus/trace/span.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ def finish(self):
370370

371371
def __iter__(self):
372372
"""Iterate through the span tree."""
373-
for span in chain(*(map(iter, self.children))):
373+
for span in chain.from_iterable(map(iter, self.children)):
374374
yield span
375375
yield self
376376

0 commit comments

Comments
 (0)