[issue33173] GzipFile's .seekable() returns True even if underlying buffer is not seekable

Serhiy Storchaka report at bugs.python.org
Fri Nov 9 03:45:28 EST 2018


Serhiy Storchaka <storchaka+cpython at gmail.com> added the comment:

I share Martin's opinion that this is a misfeature. User code can check seekable() and use seek() if it returns True or cache necessary data in memory if it returns False, because it is expected that seek() is more efficient. But in case of GzipFile it is not efficient, and can lead to decompression the whole content of the file and to much worse performance.

----------
nosy: +serhiy.storchaka

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue33173>
_______________________________________


More information about the Python-bugs-list mailing list