- Make the layer going over the estimated size raise an exception
- Add a heuristic for estimating the layer size if it is 0 - Add a method where we can add a custom defined map of image -> size
This commit is contained in:
parent
297c8ad29c
commit
746936ce66
4 changed files with 37 additions and 35 deletions
|
@ -22,7 +22,11 @@ class QueueFile(object):
|
|||
if result is None:
|
||||
self._done = True
|
||||
break
|
||||
|
||||
|
||||
if isinstance(result, Exception):
|
||||
self._closed = True
|
||||
raise result
|
||||
|
||||
self._buffer += result
|
||||
self._total_size += len(result)
|
||||
|
||||
|
|
Reference in a new issue