Issue #28227: gzip now supports pathlib

Patch by Ethan Furman.
This commit is contained in:
Berker Peksag 2016-10-02 13:47:58 +03:00
parent 8e9045d0d8
commit 03020cfa97
4 changed files with 32 additions and 1 deletions

View file

@ -56,6 +56,8 @@ The module defines the following items:
.. versionchanged:: 3.4
Added support for the ``'x'``, ``'xb'`` and ``'xt'`` modes.
.. versionchanged:: 3.6
Accepts a :term:`path-like object`.
.. class:: GzipFile(filename=None, mode=None, compresslevel=9, fileobj=None, mtime=None)
@ -151,6 +153,9 @@ The module defines the following items:
The :meth:`~io.BufferedIOBase.read` method now accepts an argument of
``None``.
.. versionchanged:: 3.6
Accepts a :term:`path-like object`.
.. function:: compress(data, compresslevel=9)