Commit d87f2ec3 authored by Phyks's avatar Phyks

Fix issue #131

parent 4ef32a56
Pipeline #85786 failed with stage
in 5 minutes and 15 seconds
......@@ -169,7 +169,10 @@ def batch(iterable, size):
sourceiter = iter(iterable)
while True:
batchiter = itertools.islice(sourceiter, size)
yield itertools.chain([next(batchiter)], batchiter)
try:
yield itertools.chain([next(batchiter)], batchiter)
except StopIteration:
return
def is_within_interval(value, min_value=None, max_value=None):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment