We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 5e45aba + 94ff8dd commit ded9752Copy full SHA for ded9752
progress/__init__.py
@@ -73,10 +73,12 @@ def next(self, n=1):
73
self.update()
74
75
def iter(self, it):
76
- for x in it:
77
- yield x
78
- self.next()
79
- self.finish()
+ try:
+ for x in it:
+ yield x
+ self.next()
80
+ finally:
81
+ self.finish()
82
83
84
class Progress(Infinite):
@@ -117,7 +119,9 @@ def iter(self, it):
117
119
except TypeError:
118
120
pass
121
122
123
124
125
126
127
0 commit comments