Method: gzip.GzipFile.flush
Calls: 25, Exceptions: 1, Paths: 3Back
Path 1: 17 calls (0.68)
2 (17)
1def flush(self,zlib_mode=zlib.Z_SYNC_FLUSH):
2 self._check_not_closed()
3 if self.mode == WRITE:
4 # Ensure the compressor's buffer is flushed
5 self.fileobj.write(self.compress.flush(zlib_mode))
6 self.fileobj.flush()
Path 2: 7 calls (0.28)
2 (7)
1def flush(self,zlib_mode=zlib.Z_SYNC_FLUSH):
2 self._check_not_closed()
3 if self.mode == WRITE:
4 # Ensure the compressor's buffer is flushed
5 self.fileobj.write(self.compress.flush(zlib_mode))
6 self.fileobj.flush()
Path 3: 1 calls (0.04)
2 (1)
ValueError (1)
1def flush(self,zlib_mode=zlib.Z_SYNC_FLUSH):
2 self._check_not_closed()
3 if self.mode == WRITE:
4 # Ensure the compressor's buffer is flushed
5 self.fileobj.write(self.compress.flush(zlib_mode))
6 self.fileobj.flush()