chunk_id
stringlengths
36
36
source
stringclasses
35 values
source_url
stringlengths
0
290
upstream_license
stringclasses
1 value
document_id
stringlengths
36
36
chunk_index
int64
0
324k
retrieved_at
stringclasses
2 values
chunker_version
stringclasses
4 values
content_hash
stringlengths
15
64
content
stringlengths
50
44.7k
namespace
stringclasses
9 values
source_name
stringclasses
35 values
raw_text
stringlengths
50
44.7k
cleaned_text
stringlengths
50
44.7k
tags
stringclasses
49 values
collection_name
stringclasses
11 values
0cfa4831-0b1a-4bf5-9bcb-8c410438b718
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,685
supabase-export-v2
718ad410bdb05c6e
Search for files :file:`\*.py` and add the corresponding file to the archive. If the *optimize* parameter to :class:`PyZipFile` was not given or ``-1``, the corresponding file is a :file:`\*.pyc` file, compiling if necessary.
trusted_official_docs
CPython Docs
Search for files :file:`\*.py` and add the corresponding file to the archive. If the *optimize* parameter to :class:`PyZipFile` was not given or ``-1``, the corresponding file is a :file:`\*.pyc` file, compiling if necessary.
Search for files :file:`\*.py` and add the corresponding file to the archive. If the *optimize* parameter to :class:`PyZipFile` was not given or ``-1``, the corresponding file is a :file:`\*.pyc` file, compiling if necessary.
python, official-docs, cpython, P0
Local_Trusted_Corpus
13f4f73d-8aad-4b86-aa57-1893a53aa17f
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,492
supabase-export-v2
44c45774c6f19ec8
from your copy of CPython, look for documentation from your distributor (that is, whoever provided Python to you). If you are the distributor, see :ref:`optional-module-requirements`. The module defines the following items:
trusted_official_docs
CPython Docs
from your copy of CPython, look for documentation from your distributor (that is, whoever provided Python to you). If you are the distributor, see :ref:`optional-module-requirements`. The module defines the following items:
from your copy of CPython, look for documentation from your distributor (that is, whoever provided Python to you). If you are the distributor, see :ref:`optional-module-requirements`. The module defines the following items:
python, official-docs, cpython, P0
Local_Trusted_Corpus
14b6853d-4a66-49c9-acaa-93b3bef65fe5
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,613
supabase-export-v2
b72ca57508d3e5d4
.. versionchanged:: 3.6 Calling :meth:`write` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised. .. method:: ZipFile.writestr(zinfo_or_arcname, data, compress_type=None, \ compresslevel=None)
trusted_official_docs
CPython Docs
.. versionchanged:: 3.6 Calling :meth:`write` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised. .. method:: ZipFile.writestr(zinfo_or_arcname, data, compress_type=None, \ compresslevel=None)
.. versionchanged:: 3.6 Calling :meth:`write` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised. .. method:: ZipFile.writestr(zinfo_or_arcname, data, compress_type=None, \ compresslevel=None)
python, official-docs, cpython, P0
Local_Trusted_Corpus
1ac814a0-79f9-4500-a383-09154d1826a8
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,572
supabase-export-v2
638dff806833ab90
:attr:`!name`, which is equivalent to the name of a file within the archive, and :attr:`!mode`, which is ``'rb'`` or ``'wb'`` depending on the input mode. When writing a file, if the file size is not known in advance but may exceed 2 GiB, pass ``force_zip64=True`` to ensure that the header format is capable of suppor...
trusted_official_docs
CPython Docs
:attr:`!name`, which is equivalent to the name of a file within the archive, and :attr:`!mode`, which is ``'rb'`` or ``'wb'`` depending on the input mode. When writing a file, if the file size is not known in advance but may exceed 2 GiB, pass ``force_zip64=True`` to ensure that the header format is capable of suppor...
:attr:`!name`, which is equivalent to the name of a file within the archive, and :attr:`!mode`, which is ``'rb'`` or ``'wb'`` depending on the input mode. When writing a file, if the file size is not known in advance but may exceed 2 GiB, pass ``force_zip64=True`` to ensure that the header format is capable of suppor...
python, official-docs, cpython, P0
Local_Trusted_Corpus
2121c533-c777-4dd7-be88-3b9b4e5b4082
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,571
supabase-export-v2
4a6a47fa5b3cdf72
the :meth:`~io.BufferedIOBase.write` method. While a writable file handle is open, attempting to read or write other files in the ZIP file will raise a :exc:`ValueError`. In both cases the file-like object has also attributes :attr:`!name`, which is equivalent to the name of a file within the archive, and :attr:`!mod...
trusted_official_docs
CPython Docs
the :meth:`~io.BufferedIOBase.write` method. While a writable file handle is open, attempting to read or write other files in the ZIP file will raise a :exc:`ValueError`. In both cases the file-like object has also attributes :attr:`!name`, which is equivalent to the name of a file within the archive, and :attr:`!mod...
the :meth:`~io.BufferedIOBase.write` method. While a writable file handle is open, attempting to read or write other files in the ZIP file will raise a :exc:`ValueError`. In both cases the file-like object has also attributes :attr:`!name`, which is equivalent to the name of a file within the archive, and :attr:`!mod...
python, official-docs, cpython, P0
Local_Trusted_Corpus
214d8145-de77-45ec-be8a-4cf36726dc02
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,538
supabase-export-v2
6273c1dafe27960a
:const:`ZIP_BZIP2`, :const:`ZIP_LZMA`, or :const:`ZIP_ZSTANDARD` is specified but the corresponding module (:mod:`zlib`, :mod:`bz2`, :mod:`lzma`, or :mod:`compression.zstd`) is not available, :exc:`RuntimeError` is raised. The default is :const:`ZIP_STORED`. If *allowZip64* is ``True`` (the default) zipfile will create...
trusted_official_docs
CPython Docs
:const:`ZIP_BZIP2`, :const:`ZIP_LZMA`, or :const:`ZIP_ZSTANDARD` is specified but the corresponding module (:mod:`zlib`, :mod:`bz2`, :mod:`lzma`, or :mod:`compression.zstd`) is not available, :exc:`RuntimeError` is raised. The default is :const:`ZIP_STORED`. If *allowZip64* is ``True`` (the default) zipfile will create...
:const:`ZIP_BZIP2`, :const:`ZIP_LZMA`, or :const:`ZIP_ZSTANDARD` is specified but the corresponding module (:mod:`zlib`, :mod:`bz2`, :mod:`lzma`, or :mod:`compression.zstd`) is not available, :exc:`RuntimeError` is raised. The default is :const:`ZIP_STORED`. If *allowZip64* is ``True`` (the default) zipfile will create...
python, official-docs, cpython, P0
Local_Trusted_Corpus
2400ead4-ab68-47eb-9453-5ce629a33bc9
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,589
supabase-export-v2
8c6c99c328386ae6
.. warning:: Never extract archives from untrusted sources without prior inspection. It is possible that files are created outside of *path*, e.g. members that have absolute filenames starting with ``"/"`` or filenames with two dots ``".."``. This module attempts to prevent that. See :meth:`extract` note.
trusted_official_docs
CPython Docs
.. warning:: Never extract archives from untrusted sources without prior inspection. It is possible that files are created outside of *path*, e.g. members that have absolute filenames starting with ``"/"`` or filenames with two dots ``".."``. This module attempts to prevent that. See :meth:`extract` note.
.. warning:: Never extract archives from untrusted sources without prior inspection. It is possible that files are created outside of *path*, e.g. members that have absolute filenames starting with ``"/"`` or filenames with two dots ``".."``. This module attempts to prevent that. See :meth:`extract` note.
python, official-docs, cpython, P0
Local_Trusted_Corpus
2a400527-896a-4eae-a8a3-44c549628734
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,614
supabase-export-v2
4e06582f1912aef1
.. method:: ZipFile.writestr(zinfo_or_arcname, data, compress_type=None, \ compresslevel=None) Write a file into the archive. The contents is *data*, which may be either a :class:`str` or a :class:`bytes` instance; if it is a :class:`str`, it is encoded as UTF-8 first. *zinfo_or_arcname* is either the file name it w...
trusted_official_docs
CPython Docs
.. method:: ZipFile.writestr(zinfo_or_arcname, data, compress_type=None, \ compresslevel=None) Write a file into the archive. The contents is *data*, which may be either a :class:`str` or a :class:`bytes` instance; if it is a :class:`str`, it is encoded as UTF-8 first. *zinfo_or_arcname* is either the file name it w...
.. method:: ZipFile.writestr(zinfo_or_arcname, data, compress_type=None, \ compresslevel=None) Write a file into the archive. The contents is *data*, which may be either a :class:`str` or a :class:`bytes` instance; if it is a :class:`str`, it is encoded as UTF-8 first. *zinfo_or_arcname* is either the file name it w...
python, official-docs, cpython, P0
Local_Trusted_Corpus
2acea1c5-028e-4fdd-aade-58eae35b55b7
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,691
supabase-export-v2
7c61834fd9d2e3d1
>>> zf = PyZipFile('myprog.zip') >>> def notests(s): ... fn = os.path.basename(s) ... return (not (fn == 'test' or fn.startswith('test_'))) ... >>> zf.writepy('myprog', filterfunc=notests) The :meth:`writepy` method makes archives with file names like this::
trusted_official_docs
CPython Docs
>>> zf = PyZipFile('myprog.zip') >>> def notests(s): ... fn = os.path.basename(s) ... return (not (fn == 'test' or fn.startswith('test_'))) ... >>> zf.writepy('myprog', filterfunc=notests) The :meth:`writepy` method makes archives with file names like this::
>>> zf = PyZipFile('myprog.zip') >>> def notests(s): ... fn = os.path.basename(s) ... return (not (fn == 'test' or fn.startswith('test_'))) ... >>> zf.writepy('myprog', filterfunc=notests) The :meth:`writepy` method makes archives with file names like this::
python, official-docs, cpython, P0
Local_Trusted_Corpus
32aa4fe2-9cc5-4719-bf47-2f49adcc8220
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,619
supabase-export-v2
b38b1cf663e64e74
.. versionchanged:: 3.2 The *compress_type* argument. .. versionchanged:: 3.6 Calling :meth:`writestr` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
trusted_official_docs
CPython Docs
.. versionchanged:: 3.2 The *compress_type* argument. .. versionchanged:: 3.6 Calling :meth:`writestr` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
.. versionchanged:: 3.2 The *compress_type* argument. .. versionchanged:: 3.6 Calling :meth:`writestr` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
python, official-docs, cpython, P0
Local_Trusted_Corpus
334d2a03-31f0-4833-a029-8d5edbe27e9e
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,687
supabase-export-v2
059165efa4896676
*optimize* parameter to :class:`PyZipFile` was ``0``, ``1`` or ``2``, only files with that optimization level (see :func:`compile`) are added to the archive, compiling if necessary. If *pathname* is a file, the filename must end with :file:`.py`, and just the (corresponding :file:`\*.pyc`) file is added at the top lev...
trusted_official_docs
CPython Docs
*optimize* parameter to :class:`PyZipFile` was ``0``, ``1`` or ``2``, only files with that optimization level (see :func:`compile`) are added to the archive, compiling if necessary. If *pathname* is a file, the filename must end with :file:`.py`, and just the (corresponding :file:`\*.pyc`) file is added at the top lev...
*optimize* parameter to :class:`PyZipFile` was ``0``, ``1`` or ``2``, only files with that optimization level (see :func:`compile`) are added to the archive, compiling if necessary. If *pathname* is a file, the filename must end with :file:`.py`, and just the (corresponding :file:`\*.pyc`) file is added at the top lev...
python, official-docs, cpython, P0
Local_Trusted_Corpus
35e6057a-7331-4018-8d7d-db6d41601309
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,537
supabase-export-v2
33dfd1c7f80a616d
*mode* is ``'a'`` and the file does not exist at all, it is created. If *mode* is ``'r'`` or ``'a'``, the file should be seekable. *compression* is the ZIP compression method to use when writing the archive, and should be :const:`ZIP_STORED`, :const:`ZIP_DEFLATED`, :const:`ZIP_BZIP2`, :const:`ZIP_LZMA`, or :const:`ZI...
trusted_official_docs
CPython Docs
*mode* is ``'a'`` and the file does not exist at all, it is created. If *mode* is ``'r'`` or ``'a'``, the file should be seekable. *compression* is the ZIP compression method to use when writing the archive, and should be :const:`ZIP_STORED`, :const:`ZIP_DEFLATED`, :const:`ZIP_BZIP2`, :const:`ZIP_LZMA`, or :const:`ZI...
*mode* is ``'a'`` and the file does not exist at all, it is created. If *mode* is ``'r'`` or ``'a'``, the file should be seekable. *compression* is the ZIP compression method to use when writing the archive, and should be :const:`ZIP_STORED`, :const:`ZIP_DEFLATED`, :const:`ZIP_BZIP2`, :const:`ZIP_LZMA`, or :const:`ZI...
python, official-docs, cpython, P0
Local_Trusted_Corpus
3c4180f9-f165-4c96-98e6-b36a039cae89
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,574
supabase-export-v2
f6776b88c01517a1
.. note:: The :meth:`.open`, :meth:`read` and :meth:`extract` methods can take a filename or a :class:`ZipInfo` object. You will appreciate this when trying to read a ZIP file that contains members with duplicate names.
trusted_official_docs
CPython Docs
.. note:: The :meth:`.open`, :meth:`read` and :meth:`extract` methods can take a filename or a :class:`ZipInfo` object. You will appreciate this when trying to read a ZIP file that contains members with duplicate names.
.. note:: The :meth:`.open`, :meth:`read` and :meth:`extract` methods can take a filename or a :class:`ZipInfo` object. You will appreciate this when trying to read a ZIP file that contains members with duplicate names.
python, official-docs, cpython, P0
Local_Trusted_Corpus
3e7ba846-88d6-4f77-945b-bda3404a3f6a
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,536
supabase-export-v2
6e58ddb9e2af799e
Open a ZIP file, where *file* can be a path to a file (a string), a file-like object or a :term:`path-like object`. The *mode* parameter should be ``'r'`` to read an existing file, ``'w'`` to truncate and write a new file, ``'a'`` to append to an existing file, or ``'x'`` to exclusively create and write a new file. I...
trusted_official_docs
CPython Docs
Open a ZIP file, where *file* can be a path to a file (a string), a file-like object or a :term:`path-like object`. The *mode* parameter should be ``'r'`` to read an existing file, ``'w'`` to truncate and write a new file, ``'a'`` to append to an existing file, or ``'x'`` to exclusively create and write a new file. I...
Open a ZIP file, where *file* can be a path to a file (a string), a file-like object or a :term:`path-like object`. The *mode* parameter should be ``'r'`` to read an existing file, ``'w'`` to truncate and write a new file, ``'a'`` to append to an existing file, or ``'x'`` to exclusively create and write a new file. I...
python, official-docs, cpython, P0
Local_Trusted_Corpus
3f2be521-c3c6-426d-a0a9-3844480024c5
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,686
supabase-export-v2
d4bc06649c4649b5
If the *optimize* parameter to :class:`PyZipFile` was not given or ``-1``, the corresponding file is a :file:`\*.pyc` file, compiling if necessary. If the *optimize* parameter to :class:`PyZipFile` was ``0``, ``1`` or ``2``, only files with that optimization level (see :func:`compile`) are added to the archive, compi...
trusted_official_docs
CPython Docs
If the *optimize* parameter to :class:`PyZipFile` was not given or ``-1``, the corresponding file is a :file:`\*.pyc` file, compiling if necessary. If the *optimize* parameter to :class:`PyZipFile` was ``0``, ``1`` or ``2``, only files with that optimization level (see :func:`compile`) are added to the archive, compi...
If the *optimize* parameter to :class:`PyZipFile` was not given or ``-1``, the corresponding file is a :file:`\*.pyc` file, compiling if necessary. If the *optimize* parameter to :class:`PyZipFile` was ``0``, ``1`` or ``2``, only files with that optimization level (see :func:`compile`) are added to the archive, compi...
python, official-docs, cpython, P0
Local_Trusted_Corpus
3fcd1cd7-fb64-4365-b838-6011a3b5329c
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,583
supabase-export-v2
66e76a83abea5d61
.. note:: If a member filename is an absolute path, a drive/UNC sharepoint and leading (back)slashes will be stripped, e.g.: ``///foo/bar`` becomes ``foo/bar`` on Unix, and ``C:\foo\bar`` becomes ``foo\bar`` on Windows. And all ``".."`` components in a member filename will be removed, e.g.: ``../../foo../../ba..r`` ...
trusted_official_docs
CPython Docs
.. note:: If a member filename is an absolute path, a drive/UNC sharepoint and leading (back)slashes will be stripped, e.g.: ``///foo/bar`` becomes ``foo/bar`` on Unix, and ``C:\foo\bar`` becomes ``foo\bar`` on Windows. And all ``".."`` components in a member filename will be removed, e.g.: ``../../foo../../ba..r`` ...
.. note:: If a member filename is an absolute path, a drive/UNC sharepoint and leading (back)slashes will be stripped, e.g.: ``///foo/bar`` becomes ``foo/bar`` on Unix, and ``C:\foo\bar`` becomes ``foo\bar`` on Windows. And all ``".."`` components in a member filename will be removed, e.g.: ``../../foo../../ba..r`` ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
43e920c6-c64c-42d3-a52b-1d2b16ee50f3
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,603
supabase-export-v2
9ba4133188ce7605
.. method:: ZipFile.write(filename, arcname=None, compress_type=None, \ compresslevel=None) Write the file named *filename* to the archive, giving it the archive name *arcname* (by default, this will be the same as *filename*, but without a drive letter and with leading path separators removed). If given, *compress_t...
trusted_official_docs
CPython Docs
.. method:: ZipFile.write(filename, arcname=None, compress_type=None, \ compresslevel=None) Write the file named *filename* to the archive, giving it the archive name *arcname* (by default, this will be the same as *filename*, but without a drive letter and with leading path separators removed). If given, *compress_t...
.. method:: ZipFile.write(filename, arcname=None, compress_type=None, \ compresslevel=None) Write the file named *filename* to the archive, giving it the archive name *arcname* (by default, this will be the same as *filename*, but without a drive letter and with leading path separators removed). If given, *compress_t...
python, official-docs, cpython, P0
Local_Trusted_Corpus
448d91ec-ca92-44c0-8a25-7e4a5a58debd
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,617
supabase-export-v2
c57d02e42897253b
.. note:: When passing a :class:`ZipInfo` instance as the *zinfo_or_arcname* parameter, the compression method used will be that specified in the *compress_type* member of the given :class:`ZipInfo` instance. By default, the :class:`ZipInfo` constructor sets this member to :const:`ZIP_STORED`.
trusted_official_docs
CPython Docs
.. note:: When passing a :class:`ZipInfo` instance as the *zinfo_or_arcname* parameter, the compression method used will be that specified in the *compress_type* member of the given :class:`ZipInfo` instance. By default, the :class:`ZipInfo` constructor sets this member to :const:`ZIP_STORED`.
.. note:: When passing a :class:`ZipInfo` instance as the *zinfo_or_arcname* parameter, the compression method used will be that specified in the *compress_type* member of the given :class:`ZipInfo` instance. By default, the :class:`ZipInfo` constructor sets this member to :const:`ZIP_STORED`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
47412b54-19c7-4bf9-bd68-c4a4871bd8bf
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,605
supabase-export-v2
ec7352ac0d8622ac
.. note:: The ZIP file standard historically did not specify a metadata encoding, but strongly recommended CP437 (the original IBM PC encoding) for interoperability. Recent versions allow use of UTF-8 (only). In this module, UTF-8 will automatically be used to write the member names if they contain any non-ASCII ch...
trusted_official_docs
CPython Docs
.. note:: The ZIP file standard historically did not specify a metadata encoding, but strongly recommended CP437 (the original IBM PC encoding) for interoperability. Recent versions allow use of UTF-8 (only). In this module, UTF-8 will automatically be used to write the member names if they contain any non-ASCII ch...
.. note:: The ZIP file standard historically did not specify a metadata encoding, but strongly recommended CP437 (the original IBM PC encoding) for interoperability. Recent versions allow use of UTF-8 (only). In this module, UTF-8 will automatically be used to write the member names if they contain any non-ASCII ch...
python, official-docs, cpython, P0
Local_Trusted_Corpus
486d36a9-43fc-4e91-ad72-988209480281
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,703
supabase-export-v2
2b39e91c9e0f9582
*filename* should be the path to a file or directory on the filesystem. If *arcname* is specified, it is used as the name within the archive. If *arcname* is not specified, the name will be the same as *filename*, but with any drive letter and leading path separators removed.
trusted_official_docs
CPython Docs
*filename* should be the path to a file or directory on the filesystem. If *arcname* is specified, it is used as the name within the archive. If *arcname* is not specified, the name will be the same as *filename*, but with any drive letter and leading path separators removed.
*filename* should be the path to a file or directory on the filesystem. If *arcname* is specified, it is used as the name within the archive. If *arcname* is not specified, the name will be the same as *filename*, but with any drive letter and leading path separators removed.
python, official-docs, cpython, P0
Local_Trusted_Corpus
4be64b26-44b7-4900-bd87-3e37b42de7ee
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,581
supabase-export-v2
d853b9ad00afe047
directory to extract to. *member* can be a filename or a :class:`ZipInfo` object. *pwd* is the password used for encrypted files as a :class:`bytes` object. Returns the normalized path created (a directory or new file).
trusted_official_docs
CPython Docs
directory to extract to. *member* can be a filename or a :class:`ZipInfo` object. *pwd* is the password used for encrypted files as a :class:`bytes` object. Returns the normalized path created (a directory or new file).
directory to extract to. *member* can be a filename or a :class:`ZipInfo` object. *pwd* is the password used for encrypted files as a :class:`bytes` object. Returns the normalized path created (a directory or new file).
python, official-docs, cpython, P0
Local_Trusted_Corpus
4cc6d94a-ae5c-4772-959a-8677a4e2db4a
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,720
supabase-export-v2
ba4dcd8b01536c0f
.. note:: The ZIP format supports multiple timestamp fields in different locations (central directory, extra fields for NTFS/UNIX systems, etc.). This attribute specifically returns the timestamp from the central directory. The central directory timestamp format in ZIP files does not support timestamps before 1980....
trusted_official_docs
CPython Docs
.. note:: The ZIP format supports multiple timestamp fields in different locations (central directory, extra fields for NTFS/UNIX systems, etc.). This attribute specifically returns the timestamp from the central directory. The central directory timestamp format in ZIP files does not support timestamps before 1980....
.. note:: The ZIP format supports multiple timestamp fields in different locations (central directory, extra fields for NTFS/UNIX systems, etc.). This attribute specifically returns the timestamp from the central directory. The central directory timestamp format in ZIP files does not support timestamps before 1980....
python, official-docs, cpython, P0
Local_Trusted_Corpus
4d5a0382-41a3-47d2-899d-5810912cf293
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,507
supabase-export-v2
fce908036b7318b7
.. class:: ZipInfo(filename='NoName', date_time=(1980,1,1,0,0,0)) Class used to represent information about a member of an archive. Instances of this class are returned by the :meth:`.getinfo` and :meth:`.infolist` methods of :class:`ZipFile` objects. Most users of the :mod:`!zipfile` module will not need to create ...
trusted_official_docs
CPython Docs
.. class:: ZipInfo(filename='NoName', date_time=(1980,1,1,0,0,0)) Class used to represent information about a member of an archive. Instances of this class are returned by the :meth:`.getinfo` and :meth:`.infolist` methods of :class:`ZipFile` objects. Most users of the :mod:`!zipfile` module will not need to create ...
.. class:: ZipInfo(filename='NoName', date_time=(1980,1,1,0,0,0)) Class used to represent information about a member of an archive. Instances of this class are returned by the :meth:`.getinfo` and :meth:`.infolist` methods of :class:`ZipFile` objects. Most users of the :mod:`!zipfile` module will not need to create ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
50bd85f9-8968-4cee-9599-0ce7dbaf5766
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,689
supabase-export-v2
03c65069215379ca
*basename* is intended for internal use only. *filterfunc*, if given, must be a function taking a single string argument. It will be passed each path (including each individual full file path) before it is added to the archive. If *filterfunc* returns a false value, the path will not be added, and if it is a directo...
trusted_official_docs
CPython Docs
*basename* is intended for internal use only. *filterfunc*, if given, must be a function taking a single string argument. It will be passed each path (including each individual full file path) before it is added to the archive. If *filterfunc* returns a false value, the path will not be added, and if it is a directo...
*basename* is intended for internal use only. *filterfunc*, if given, must be a function taking a single string argument. It will be passed each path (including each individual full file path) before it is added to the archive. If *filterfunc* returns a false value, the path will not be added, and if it is a directo...
python, official-docs, cpython, P0
Local_Trusted_Corpus
52f0d50c-2575-4293-b1c9-e59f384be770
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,702
supabase-export-v2
0dc7e5f9ab482d0c
Construct a :class:`ZipInfo` instance for a file on the filesystem, in preparation for adding it to a zip file. *filename* should be the path to a file or directory on the filesystem.
trusted_official_docs
CPython Docs
Construct a :class:`ZipInfo` instance for a file on the filesystem, in preparation for adding it to a zip file. *filename* should be the path to a file or directory on the filesystem.
Construct a :class:`ZipInfo` instance for a file on the filesystem, in preparation for adding it to a zip file. *filename* should be the path to a file or directory on the filesystem.
python, official-docs, cpython, P0
Local_Trusted_Corpus
533e6ba6-24f1-4e32-ab0f-561d088e74b0
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,597
supabase-export-v2
b087713744700d6e
.. method:: ZipFile.read(name, pwd=None) Return the bytes of the file *name* in the archive. *name* is the name of the file in the archive, or a :class:`ZipInfo` object. The archive must be open for read or append. *pwd* is the password used for encrypted files as a :class:`bytes` object and, if specified, overrides...
trusted_official_docs
CPython Docs
.. method:: ZipFile.read(name, pwd=None) Return the bytes of the file *name* in the archive. *name* is the name of the file in the archive, or a :class:`ZipInfo` object. The archive must be open for read or append. *pwd* is the password used for encrypted files as a :class:`bytes` object and, if specified, overrides...
.. method:: ZipFile.read(name, pwd=None) Return the bytes of the file *name* in the archive. *name* is the name of the file in the archive, or a :class:`ZipInfo` object. The archive must be open for read or append. *pwd* is the password used for encrypted files as a :class:`bytes` object and, if specified, overrides...
python, official-docs, cpython, P0
Local_Trusted_Corpus
54e1e6fe-06c3-4186-99f6-07bd2bf91977
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,636
supabase-export-v2
e21f4d3cc66801b4
``at`` specifies the location of this Path within the zipfile, e.g. 'dir/file.txt', 'dir/', or ''. Defaults to the empty string, indicating the root. .. note:: The :class:`Path` class does not sanitize filenames within the ZIP archive. Unlike the :meth:`ZipFile.extract` and :meth:`ZipFile.extractall` methods, it is t...
trusted_official_docs
CPython Docs
``at`` specifies the location of this Path within the zipfile, e.g. 'dir/file.txt', 'dir/', or ''. Defaults to the empty string, indicating the root. .. note:: The :class:`Path` class does not sanitize filenames within the ZIP archive. Unlike the :meth:`ZipFile.extract` and :meth:`ZipFile.extractall` methods, it is t...
``at`` specifies the location of this Path within the zipfile, e.g. 'dir/file.txt', 'dir/', or ''. Defaults to the empty string, indicating the root. .. note:: The :class:`Path` class does not sanitize filenames within the ZIP archive. Unlike the :meth:`ZipFile.extract` and :meth:`ZipFile.extractall` methods, it is t...
python, official-docs, cpython, P0
Local_Trusted_Corpus
638b2de5-3db1-4ac9-8faa-0fb7862b83dc
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,716
supabase-export-v2
a785387be797b0c6
.. attribute:: ZipInfo.date_time The time and date of the last modification to the archive member. This is a tuple of six values representing the "last [modified] file time" and "last [modified] file date" fields from the ZIP file's central directory.
trusted_official_docs
CPython Docs
.. attribute:: ZipInfo.date_time The time and date of the last modification to the archive member. This is a tuple of six values representing the "last [modified] file time" and "last [modified] file date" fields from the ZIP file's central directory.
.. attribute:: ZipInfo.date_time The time and date of the last modification to the archive member. This is a tuple of six values representing the "last [modified] file time" and "last [modified] file date" fields from the ZIP file's central directory.
python, official-docs, cpython, P0
Local_Trusted_Corpus
66100fb7-6ab1-4f0b-abdf-7f4ccd2f70d7
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,699
supabase-export-v2
4b9d8467429f4e3f
:class:`ZipInfo` class are returned by the :meth:`.getinfo` and :meth:`.infolist` methods of :class:`ZipFile` objects. Each object stores information about a single member of the ZIP archive. There is one classmethod to make a :class:`ZipInfo` instance for a filesystem file:
trusted_official_docs
CPython Docs
:class:`ZipInfo` class are returned by the :meth:`.getinfo` and :meth:`.infolist` methods of :class:`ZipFile` objects. Each object stores information about a single member of the ZIP archive. There is one classmethod to make a :class:`ZipInfo` instance for a filesystem file:
:class:`ZipInfo` class are returned by the :meth:`.getinfo` and :meth:`.infolist` methods of :class:`ZipFile` objects. Each object stores information about a single member of the ZIP archive. There is one classmethod to make a :class:`ZipInfo` instance for a filesystem file:
python, official-docs, cpython, P0
Local_Trusted_Corpus
6caf6f66-ae47-4f6a-803d-aaae5eb55f43
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,690
supabase-export-v2
e842741f78ba046e
example, if our test files are all either in ``test`` directories or start with the string ``test_``, we can use a *filterfunc* to exclude them:: >>> zf = PyZipFile('myprog.zip') >>> def notests(s): ... fn = os.path.basename(s) ... return (not (fn == 'test' or fn.startswith('test_'))) ... >>> zf.writepy('myprog', f...
trusted_official_docs
CPython Docs
example, if our test files are all either in ``test`` directories or start with the string ``test_``, we can use a *filterfunc* to exclude them:: >>> zf = PyZipFile('myprog.zip') >>> def notests(s): ... fn = os.path.basename(s) ... return (not (fn == 'test' or fn.startswith('test_'))) ... >>> zf.writepy('myprog', f...
example, if our test files are all either in ``test`` directories or start with the string ``test_``, we can use a *filterfunc* to exclude them:: >>> zf = PyZipFile('myprog.zip') >>> def notests(s): ... fn = os.path.basename(s) ... return (not (fn == 'test' or fn.startswith('test_'))) ... >>> zf.writepy('myprog', f...
python, official-docs, cpython, P0
Local_Trusted_Corpus
73139194-ecf5-4612-b059-b06b9570384a
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,587
supabase-export-v2
aadb89edad02e97a
.. method:: ZipFile.extractall(path=None, members=None, pwd=None) Extract all members from the archive to the current working directory. *path* specifies a different directory to extract to. *members* is optional and must be a subset of the list returned by :meth:`namelist`. *pwd* is the password used for encrypted ...
trusted_official_docs
CPython Docs
.. method:: ZipFile.extractall(path=None, members=None, pwd=None) Extract all members from the archive to the current working directory. *path* specifies a different directory to extract to. *members* is optional and must be a subset of the list returned by :meth:`namelist`. *pwd* is the password used for encrypted ...
.. method:: ZipFile.extractall(path=None, members=None, pwd=None) Extract all members from the archive to the current working directory. *path* specifies a different directory to extract to. *members* is optional and must be a subset of the list returned by :meth:`namelist`. *pwd* is the password used for encrypted ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
7610c012-510c-4538-b3b5-3c2861e14da5
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,620
supabase-export-v2
6fead55e9279a4c5
.. versionchanged:: 3.6 Calling :meth:`writestr` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised. .. versionchanged:: 3.14 Now respects the :envvar:`SOURCE_DATE_EPOCH` environment variable. If set, it uses this value as the modific...
trusted_official_docs
CPython Docs
.. versionchanged:: 3.6 Calling :meth:`writestr` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised. .. versionchanged:: 3.14 Now respects the :envvar:`SOURCE_DATE_EPOCH` environment variable. If set, it uses this value as the modific...
.. versionchanged:: 3.6 Calling :meth:`writestr` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised. .. versionchanged:: 3.14 Now respects the :envvar:`SOURCE_DATE_EPOCH` environment variable. If set, it uses this value as the modific...
python, official-docs, cpython, P0
Local_Trusted_Corpus
7e7ff7f6-5240-42b6-98ff-b8590b62c948
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,622
supabase-export-v2
2a7239d664bd4b65
.. method:: ZipFile.mkdir(zinfo_or_directory, mode=511) Create a directory inside the archive. If *zinfo_or_directory* is a string, a directory is created inside the archive with the mode that is specified in the *mode* argument. If, however, *zinfo_or_directory* is a :class:`ZipInfo` instance then the *mode* argume...
trusted_official_docs
CPython Docs
.. method:: ZipFile.mkdir(zinfo_or_directory, mode=511) Create a directory inside the archive. If *zinfo_or_directory* is a string, a directory is created inside the archive with the mode that is specified in the *mode* argument. If, however, *zinfo_or_directory* is a :class:`ZipInfo` instance then the *mode* argume...
.. method:: ZipFile.mkdir(zinfo_or_directory, mode=511) Create a directory inside the archive. If *zinfo_or_directory* is a string, a directory is created inside the archive with the mode that is specified in the *mode* argument. If, however, *zinfo_or_directory* is a :class:`ZipInfo` instance then the *mode* argume...
python, official-docs, cpython, P0
Local_Trusted_Corpus
7edba71d-e5c7-4c24-bbe2-5991b8a1f9a3
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,692
supabase-export-v2
c3738a7673ed0e51
The :meth:`writepy` method makes archives with file names like this:: string.pyc # Top level name test/__init__.pyc # Package directory test/testall.pyc # Module test.testall test/bogus/__init__.pyc # Subpackage directory test/bogus/myfile.pyc # Submodule test.bogus.myfile
trusted_official_docs
CPython Docs
The :meth:`writepy` method makes archives with file names like this:: string.pyc # Top level name test/__init__.pyc # Package directory test/testall.pyc # Module test.testall test/bogus/__init__.pyc # Subpackage directory test/bogus/myfile.pyc # Submodule test.bogus.myfile
The :meth:`writepy` method makes archives with file names like this:: string.pyc # Top level name test/__init__.pyc # Package directory test/testall.pyc # Module test.testall test/bogus/__init__.pyc # Subpackage directory test/bogus/myfile.pyc # Submodule test.bogus.myfile
python, official-docs, cpython, P0
Local_Trusted_Corpus
7f4c768d-d4b8-41ea-a2a7-a4335631d3ad
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,668
supabase-export-v2
a8179c5adc95c28e
Read the current file as unicode text. Positional and keyword arguments are passed through to :class:`io.TextIOWrapper` (except ``buffer``, which is implied by the context). .. versionchanged:: 3.11.2 The ``encoding`` parameter can be supplied as a positional argument without causing a :exc:`TypeError`. As it could i...
trusted_official_docs
CPython Docs
Read the current file as unicode text. Positional and keyword arguments are passed through to :class:`io.TextIOWrapper` (except ``buffer``, which is implied by the context). .. versionchanged:: 3.11.2 The ``encoding`` parameter can be supplied as a positional argument without causing a :exc:`TypeError`. As it could i...
Read the current file as unicode text. Positional and keyword arguments are passed through to :class:`io.TextIOWrapper` (except ``buffer``, which is implied by the context). .. versionchanged:: 3.11.2 The ``encoding`` parameter can be supplied as a positional argument without causing a :exc:`TypeError`. As it could i...
python, official-docs, cpython, P0
Local_Trusted_Corpus
81f2f298-d5ce-4b5e-9650-3fb6a235d186
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,575
supabase-export-v2
f73f0153a2d27122
can take a filename or a :class:`ZipInfo` object. You will appreciate this when trying to read a ZIP file that contains members with duplicate names. .. versionchanged:: 3.6 Removed support of ``mode='U'``. Use :class:`io.TextIOWrapper` for reading compressed text files in :term:`universal newlines` mode.
trusted_official_docs
CPython Docs
can take a filename or a :class:`ZipInfo` object. You will appreciate this when trying to read a ZIP file that contains members with duplicate names. .. versionchanged:: 3.6 Removed support of ``mode='U'``. Use :class:`io.TextIOWrapper` for reading compressed text files in :term:`universal newlines` mode.
can take a filename or a :class:`ZipInfo` object. You will appreciate this when trying to read a ZIP file that contains members with duplicate names. .. versionchanged:: 3.6 Removed support of ``mode='U'``. Use :class:`io.TextIOWrapper` for reading compressed text files in :term:`universal newlines` mode.
python, official-docs, cpython, P0
Local_Trusted_Corpus
87140a68-67df-422f-9fe7-f11d5a54bf57
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,788
supabase-export-v2
3327c67361cf683c
Not knowing the default extraction behaviors can cause unexpected decompression results. For example, when extracting the same archive twice, it overwrites files without asking. .. _ZIP bomb: https://en.wikipedia.org/wiki/Zip_bomb .. _PKZIP Application Note: https://pkware.cachefly.net/webdocs/casestudies/APPNOTE.TXT
trusted_official_docs
CPython Docs
Not knowing the default extraction behaviors can cause unexpected decompression results. For example, when extracting the same archive twice, it overwrites files without asking. .. _ZIP bomb: https://en.wikipedia.org/wiki/Zip_bomb .. _PKZIP Application Note: https://pkware.cachefly.net/webdocs/casestudies/APPNOTE.TXT
Not knowing the default extraction behaviors can cause unexpected decompression results. For example, when extracting the same archive twice, it overwrites files without asking. .. _ZIP bomb: https://en.wikipedia.org/wiki/Zip_bomb .. _PKZIP Application Note: https://pkware.cachefly.net/webdocs/casestudies/APPNOTE.TXT
python, official-docs, cpython, P0
Local_Trusted_Corpus
88796984-79d7-4465-afd4-2c3550619589
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,577
supabase-export-v2
33d7f0ae1f7400bf
.. versionchanged:: 3.6 :meth:`ZipFile.open` can now be used to write files into the archive with the ``mode='w'`` option. .. versionchanged:: 3.6 Calling :meth:`.open` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
trusted_official_docs
CPython Docs
.. versionchanged:: 3.6 :meth:`ZipFile.open` can now be used to write files into the archive with the ``mode='w'`` option. .. versionchanged:: 3.6 Calling :meth:`.open` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
.. versionchanged:: 3.6 :meth:`ZipFile.open` can now be used to write files into the archive with the ``mode='w'`` option. .. versionchanged:: 3.6 Calling :meth:`.open` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
python, official-docs, cpython, P0
Local_Trusted_Corpus
8933c0df-3ebb-467e-b6c1-5cdc565bd0ef
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,540
supabase-export-v2
1f0fc877430d2c6f
for more information). When using :const:`ZIP_ZSTANDARD` integers ``-131072`` through ``22`` are commonly accepted (see :attr:`CompressionParameter.compression_level <compression.zstd.CompressionParameter.compression_level>` for more on retrieving valid values and their meaning). The *strict_timestamps* argument, when ...
trusted_official_docs
CPython Docs
for more information). When using :const:`ZIP_ZSTANDARD` integers ``-131072`` through ``22`` are commonly accepted (see :attr:`CompressionParameter.compression_level <compression.zstd.CompressionParameter.compression_level>` for more on retrieving valid values and their meaning). The *strict_timestamps* argument, when ...
for more information). When using :const:`ZIP_ZSTANDARD` integers ``-131072`` through ``22`` are commonly accepted (see :attr:`CompressionParameter.compression_level <compression.zstd.CompressionParameter.compression_level>` for more on retrieving valid values and their meaning). The *strict_timestamps* argument, when ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
8b900cb3-671f-48af-8894-a380bb29e40e
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,615
supabase-export-v2
ddba1663fb0b317d
a name, the date and time is set to the current date and time. The archive must be opened with mode ``'w'``, ``'x'`` or ``'a'``. If given, *compress_type* overrides the value given for the *compression* parameter to the constructor for the new entry, or in the *zinfo_or_arcname* (if that is a :class:`ZipInfo` instanc...
trusted_official_docs
CPython Docs
a name, the date and time is set to the current date and time. The archive must be opened with mode ``'w'``, ``'x'`` or ``'a'``. If given, *compress_type* overrides the value given for the *compression* parameter to the constructor for the new entry, or in the *zinfo_or_arcname* (if that is a :class:`ZipInfo` instanc...
a name, the date and time is set to the current date and time. The archive must be opened with mode ``'w'``, ``'x'`` or ``'a'``. If given, *compress_type* overrides the value given for the *compression* parameter to the constructor for the new entry, or in the *zinfo_or_arcname* (if that is a :class:`ZipInfo` instanc...
python, official-docs, cpython, P0
Local_Trusted_Corpus
8d29b5a5-4029-485d-bf60-1a7bccb02b98
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,535
supabase-export-v2
d7008cd125011cd9
.. class:: ZipFile(file, mode='r', compression=ZIP_STORED, allowZip64=True, \ compresslevel=None, *, strict_timestamps=True, \ metadata_encoding=None) Open a ZIP file, where *file* can be a path to a file (a string), a file-like object or a :term:`path-like object`.
trusted_official_docs
CPython Docs
.. class:: ZipFile(file, mode='r', compression=ZIP_STORED, allowZip64=True, \ compresslevel=None, *, strict_timestamps=True, \ metadata_encoding=None) Open a ZIP file, where *file* can be a path to a file (a string), a file-like object or a :term:`path-like object`.
.. class:: ZipFile(file, mode='r', compression=ZIP_STORED, allowZip64=True, \ compresslevel=None, *, strict_timestamps=True, \ metadata_encoding=None) Open a ZIP file, where *file* can be a path to a file (a string), a file-like object or a :term:`path-like object`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
8e617aac-344a-4045-a2ec-52bf7453a503
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,514
supabase-export-v2
852ee1acefff905a
``True`` if *filename* is a valid ZIP file based on its magic number, otherwise returns ``False``. *filename* may be a file or file-like object too. .. versionchanged:: 3.1 Support for file and file-like objects.
trusted_official_docs
CPython Docs
``True`` if *filename* is a valid ZIP file based on its magic number, otherwise returns ``False``. *filename* may be a file or file-like object too. .. versionchanged:: 3.1 Support for file and file-like objects.
``True`` if *filename* is a valid ZIP file based on its magic number, otherwise returns ``False``. *filename* may be a file or file-like object too. .. versionchanged:: 3.1 Support for file and file-like objects.
python, official-docs, cpython, P0
Local_Trusted_Corpus
903f0265-c2bc-48a6-ad49-60e8e23919a7
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,567
supabase-export-v2
91ff91eff1739c0d
*mode* parameter, if included, must be ``'r'`` (the default) or ``'w'``. *pwd* is the password used to decrypt encrypted ZIP files as a :class:`bytes` object. :meth:`~ZipFile.open` is also a context manager and therefore supports the :keyword:`with` statement::
trusted_official_docs
CPython Docs
*mode* parameter, if included, must be ``'r'`` (the default) or ``'w'``. *pwd* is the password used to decrypt encrypted ZIP files as a :class:`bytes` object. :meth:`~ZipFile.open` is also a context manager and therefore supports the :keyword:`with` statement::
*mode* parameter, if included, must be ``'r'`` (the default) or ``'w'``. *pwd* is the password used to decrypt encrypted ZIP files as a :class:`bytes` object. :meth:`~ZipFile.open` is also a context manager and therefore supports the :keyword:`with` statement::
python, official-docs, cpython, P0
Local_Trusted_Corpus
93c293cd-10b0-4848-853c-d0f54c3b7ab3
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,548
supabase-export-v2
abeba90cfb79f20f
either IBM code page (default) or UTF-8 by a flag in the archive header. That flag takes precedence over *metadata_encoding*, which is a Python-specific extension. .. versionchanged:: 3.2 Added the ability to use :class:`ZipFile` as a context manager.
trusted_official_docs
CPython Docs
either IBM code page (default) or UTF-8 by a flag in the archive header. That flag takes precedence over *metadata_encoding*, which is a Python-specific extension. .. versionchanged:: 3.2 Added the ability to use :class:`ZipFile` as a context manager.
either IBM code page (default) or UTF-8 by a flag in the archive header. That flag takes precedence over *metadata_encoding*, which is a Python-specific extension. .. versionchanged:: 3.2 Added the ability to use :class:`ZipFile` as a context manager.
python, official-docs, cpython, P0
Local_Trusted_Corpus
96bce7fc-63a0-42d3-8887-086321433d30
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,490
supabase-export-v2
1bb2cab454d528a2
files in ZIP archives, but it cannot create an encrypted file. Decryption is extremely slow as it is implemented in native Python rather than C. .. The following paragraph should be similar to ../includes/optional-module.rst
trusted_official_docs
CPython Docs
files in ZIP archives, but it cannot create an encrypted file. Decryption is extremely slow as it is implemented in native Python rather than C. .. The following paragraph should be similar to ../includes/optional-module.rst
files in ZIP archives, but it cannot create an encrypted file. Decryption is extremely slow as it is implemented in native Python rather than C. .. The following paragraph should be similar to ../includes/optional-module.rst
python, official-docs, cpython, P0
Local_Trusted_Corpus
991a75d5-26cf-4638-b4ba-86d0164ba048
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,644
supabase-export-v2
91fa1b88a843a4fc
.. versionchanged:: 3.9 Added support for text and binary modes for open. Default mode is now text. .. versionchanged:: 3.11.2 The ``encoding`` parameter can be supplied as a positional argument without causing a :exc:`TypeError`. As it could in 3.9. Code needing to be compatible with unpatched 3.10 and 3.11 version...
trusted_official_docs
CPython Docs
.. versionchanged:: 3.9 Added support for text and binary modes for open. Default mode is now text. .. versionchanged:: 3.11.2 The ``encoding`` parameter can be supplied as a positional argument without causing a :exc:`TypeError`. As it could in 3.9. Code needing to be compatible with unpatched 3.10 and 3.11 version...
.. versionchanged:: 3.9 Added support for text and binary modes for open. Default mode is now text. .. versionchanged:: 3.11.2 The ``encoding`` parameter can be supplied as a positional argument without causing a :exc:`TypeError`. As it could in 3.9. Code needing to be compatible with unpatched 3.10 and 3.11 version...
python, official-docs, cpython, P0
Local_Trusted_Corpus
996aea98-7ab7-4b53-a7e2-b0fc660c8125
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,539
supabase-export-v2
435b17b682fa6d3f
when the zipfile is larger than 4 GiB. If it is ``false`` :mod:`!zipfile` will raise an exception when the ZIP file would require ZIP64 extensions. The *compresslevel* parameter controls the compression level to use when writing files to the archive. When using :const:`ZIP_STORED` or :const:`ZIP_LZMA` it has no effect...
trusted_official_docs
CPython Docs
when the zipfile is larger than 4 GiB. If it is ``false`` :mod:`!zipfile` will raise an exception when the ZIP file would require ZIP64 extensions. The *compresslevel* parameter controls the compression level to use when writing files to the archive. When using :const:`ZIP_STORED` or :const:`ZIP_LZMA` it has no effect...
when the zipfile is larger than 4 GiB. If it is ``false`` :mod:`!zipfile` will raise an exception when the ZIP file would require ZIP64 extensions. The *compresslevel* parameter controls the compression level to use when writing files to the archive. When using :const:`ZIP_STORED` or :const:`ZIP_LZMA` it has no effect...
python, official-docs, cpython, P0
Local_Trusted_Corpus
9c1bf336-c5e9-4944-a76e-79a5457aeed7
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,629
supabase-export-v2
1a812b83c61cfdc8
.. attribute:: ZipFile.debug The level of debug output to use. This may be set from ``0`` (the default, no output) to ``3`` (the most output). Debugging information is written to ``sys.stdout``.
trusted_official_docs
CPython Docs
.. attribute:: ZipFile.debug The level of debug output to use. This may be set from ``0`` (the default, no output) to ``3`` (the most output). Debugging information is written to ``sys.stdout``.
.. attribute:: ZipFile.debug The level of debug output to use. This may be set from ``0`` (the default, no output) to ``3`` (the most output). Debugging information is written to ``sys.stdout``.
python, official-docs, cpython, P0
Local_Trusted_Corpus
9f0c3388-2595-4653-a5bf-e755a4fdd731
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,721
supabase-export-v2
93f2608607d881ab
support timestamps before 1980. While some extra field formats (such as UNIX timestamps) can represent earlier dates, this attribute only returns the central directory timestamp. The central directory timestamp is interpreted as representing local time, rather than UTC time, to match the behavior of other zip tools.
trusted_official_docs
CPython Docs
support timestamps before 1980. While some extra field formats (such as UNIX timestamps) can represent earlier dates, this attribute only returns the central directory timestamp. The central directory timestamp is interpreted as representing local time, rather than UTC time, to match the behavior of other zip tools.
support timestamps before 1980. While some extra field formats (such as UNIX timestamps) can represent earlier dates, this attribute only returns the central directory timestamp. The central directory timestamp is interpreted as representing local time, rather than UTC time, to match the behavior of other zip tools.
python, official-docs, cpython, P0
Local_Trusted_Corpus
9f6bf8e9-c056-402f-aae8-26644660ad0e
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,566
supabase-export-v2
4c118372a483a426
.. method:: ZipFile.open(name, mode='r', pwd=None, *, force_zip64=False) Access a member of the archive as a binary file-like object. *name* can be either the name of a file within the archive or a :class:`ZipInfo` object. The *mode* parameter, if included, must be ``'r'`` (the default) or ``'w'``. *pwd* is the pass...
trusted_official_docs
CPython Docs
.. method:: ZipFile.open(name, mode='r', pwd=None, *, force_zip64=False) Access a member of the archive as a binary file-like object. *name* can be either the name of a file within the archive or a :class:`ZipInfo` object. The *mode* parameter, if included, must be ``'r'`` (the default) or ``'w'``. *pwd* is the pass...
.. method:: ZipFile.open(name, mode='r', pwd=None, *, force_zip64=False) Access a member of the archive as a binary file-like object. *name* can be either the name of a file within the archive or a :class:`ZipInfo` object. The *mode* parameter, if included, must be ``'r'`` (the default) or ``'w'``. *pwd* is the pass...
python, official-docs, cpython, P0
Local_Trusted_Corpus
a01f176c-2829-42d7-9a7b-51177bc7d2bf
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,751
supabase-export-v2
cf3e38f6a5c7eb30
The :mod:`!zipfile` module provides a simple command-line interface to interact with ZIP archives. If you want to create a new ZIP archive, specify its name after the :option:`-c` option and then list the filename(s) that should be included:
trusted_official_docs
CPython Docs
The :mod:`!zipfile` module provides a simple command-line interface to interact with ZIP archives. If you want to create a new ZIP archive, specify its name after the :option:`-c` option and then list the filename(s) that should be included:
The :mod:`!zipfile` module provides a simple command-line interface to interact with ZIP archives. If you want to create a new ZIP archive, specify its name after the :option:`-c` option and then list the filename(s) that should be included:
python, official-docs, cpython, P0
Local_Trusted_Corpus
a192995c-be00-4b92-a64d-02247370c7af
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,675
supabase-export-v2
1653417eea6a2654
.. versionchanged:: 3.10 Prior to 3.10, ``joinpath`` was undocumented and accepted exactly one parameter. The :pypi:`zipp` project provides backports of the latest path object functionality to older Pythons. Use ``zipp.Path`` in place of ``zipfile.Path`` for early access to changes.
trusted_official_docs
CPython Docs
.. versionchanged:: 3.10 Prior to 3.10, ``joinpath`` was undocumented and accepted exactly one parameter. The :pypi:`zipp` project provides backports of the latest path object functionality to older Pythons. Use ``zipp.Path`` in place of ``zipfile.Path`` for early access to changes.
.. versionchanged:: 3.10 Prior to 3.10, ``joinpath`` was undocumented and accepted exactly one parameter. The :pypi:`zipp` project provides backports of the latest path object functionality to older Pythons. Use ``zipp.Path`` in place of ``zipfile.Path`` for early access to changes.
python, official-docs, cpython, P0
Local_Trusted_Corpus
a210a127-e698-471c-addf-b9e047ffec23
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,601
supabase-export-v2
0fc0dcb582a7dfd2
all the files in the archive and check their CRC's and file headers. Return the name of the first bad file, or else return ``None``. .. versionchanged:: 3.6 Calling :meth:`testzip` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
trusted_official_docs
CPython Docs
all the files in the archive and check their CRC's and file headers. Return the name of the first bad file, or else return ``None``. .. versionchanged:: 3.6 Calling :meth:`testzip` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
all the files in the archive and check their CRC's and file headers. Return the name of the first bad file, or else return ``None``. .. versionchanged:: 3.6 Calling :meth:`testzip` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
python, official-docs, cpython, P0
Local_Trusted_Corpus
a68fabea-8c67-4504-b282-e2a32726b839
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,783
supabase-export-v2
1738cffabf54c8d0
Resources limitations ~~~~~~~~~~~~~~~~~~~~~ The lack of memory or disk volume would lead to decompression failed. For example, decompression bombs (aka `ZIP bomb`_) apply to zipfile library that can cause disk volume exhaustion.
trusted_official_docs
CPython Docs
Resources limitations ~~~~~~~~~~~~~~~~~~~~~ The lack of memory or disk volume would lead to decompression failed. For example, decompression bombs (aka `ZIP bomb`_) apply to zipfile library that can cause disk volume exhaustion.
Resources limitations ~~~~~~~~~~~~~~~~~~~~~ The lack of memory or disk volume would lead to decompression failed. For example, decompression bombs (aka `ZIP bomb`_) apply to zipfile library that can cause disk volume exhaustion.
python, official-docs, cpython, P0
Local_Trusted_Corpus
a74918e6-172e-43e6-85f6-5a1f1acccc2b
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,635
supabase-export-v2
d20f5dfd261c9e7f
Construct a Path object from a ``root`` zipfile (which may be a :class:`ZipFile` instance or ``file`` suitable for passing to the :class:`ZipFile` constructor). ``at`` specifies the location of this Path within the zipfile, e.g. 'dir/file.txt', 'dir/', or ''. Defaults to the empty string, indicating the root.
trusted_official_docs
CPython Docs
Construct a Path object from a ``root`` zipfile (which may be a :class:`ZipFile` instance or ``file`` suitable for passing to the :class:`ZipFile` constructor). ``at`` specifies the location of this Path within the zipfile, e.g. 'dir/file.txt', 'dir/', or ''. Defaults to the empty string, indicating the root.
Construct a Path object from a ``root`` zipfile (which may be a :class:`ZipFile` instance or ``file`` suitable for passing to the :class:`ZipFile` constructor). ``at`` specifies the location of this Path within the zipfile, e.g. 'dir/file.txt', 'dir/', or ''. Defaults to the empty string, indicating the root.
python, official-docs, cpython, P0
Local_Trusted_Corpus
b12aa56f-8f9a-480c-9b07-d37bf8faa8c0
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,643
supabase-export-v2
73bd6fb73fbfcc87
'rb', 'wb'. Positional and keyword arguments are passed through to :class:`io.TextIOWrapper` when opened as text and ignored otherwise. ``pwd`` is the ``pwd`` parameter to :meth:`ZipFile.open`. .. versionchanged:: 3.9 Added support for text and binary modes for open. Default mode is now text.
trusted_official_docs
CPython Docs
'rb', 'wb'. Positional and keyword arguments are passed through to :class:`io.TextIOWrapper` when opened as text and ignored otherwise. ``pwd`` is the ``pwd`` parameter to :meth:`ZipFile.open`. .. versionchanged:: 3.9 Added support for text and binary modes for open. Default mode is now text.
'rb', 'wb'. Positional and keyword arguments are passed through to :class:`io.TextIOWrapper` when opened as text and ignored otherwise. ``pwd`` is the ``pwd`` parameter to :meth:`ZipFile.open`. .. versionchanged:: 3.9 Added support for text and binary modes for open. Default mode is now text.
python, official-docs, cpython, P0
Local_Trusted_Corpus
b3b2b7ef-c250-4325-a436-a7a35c9dbd08
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,704
supabase-export-v2
fba264d4c76170bf
the archive. If *arcname* is not specified, the name will be the same as *filename*, but with any drive letter and leading path separators removed. The *strict_timestamps* argument, when set to ``False``, allows to zip files older than 1980-01-01 at the cost of setting the timestamp to 1980-01-01. Similar behavior oc...
trusted_official_docs
CPython Docs
the archive. If *arcname* is not specified, the name will be the same as *filename*, but with any drive letter and leading path separators removed. The *strict_timestamps* argument, when set to ``False``, allows to zip files older than 1980-01-01 at the cost of setting the timestamp to 1980-01-01. Similar behavior oc...
the archive. If *arcname* is not specified, the name will be the same as *filename*, but with any drive letter and leading path separators removed. The *strict_timestamps* argument, when set to ``False``, allows to zip files older than 1980-01-01 at the cost of setting the timestamp to 1980-01-01. Similar behavior oc...
python, official-docs, cpython, P0
Local_Trusted_Corpus
b49f0dd5-992a-46b4-94b4-5106c360833e
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,590
supabase-export-v2
024b26a7c667be22
*path*, e.g. members that have absolute filenames starting with ``"/"`` or filenames with two dots ``".."``. This module attempts to prevent that. See :meth:`extract` note. .. versionchanged:: 3.6 Calling :meth:`extractall` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was rais...
trusted_official_docs
CPython Docs
*path*, e.g. members that have absolute filenames starting with ``"/"`` or filenames with two dots ``".."``. This module attempts to prevent that. See :meth:`extract` note. .. versionchanged:: 3.6 Calling :meth:`extractall` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was rais...
*path*, e.g. members that have absolute filenames starting with ``"/"`` or filenames with two dots ``".."``. This module attempts to prevent that. See :meth:`extract` note. .. versionchanged:: 3.6 Calling :meth:`extractall` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was rais...
python, official-docs, cpython, P0
Local_Trusted_Corpus
c04ece9e-fa24-480d-a504-b6ef30c548d6
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,544
supabase-export-v2
15807f332d047c6c
context manager and therefore supports the :keyword:`with` statement. In the example, *myzip* is closed after the :keyword:`!with` statement's suite is finished---even if an exception occurs:: with ZipFile('spam.zip', 'w') as myzip: myzip.write('eggs.txt')
trusted_official_docs
CPython Docs
context manager and therefore supports the :keyword:`with` statement. In the example, *myzip* is closed after the :keyword:`!with` statement's suite is finished---even if an exception occurs:: with ZipFile('spam.zip', 'w') as myzip: myzip.write('eggs.txt')
context manager and therefore supports the :keyword:`with` statement. In the example, *myzip* is closed after the :keyword:`!with` statement's suite is finished---even if an exception occurs:: with ZipFile('spam.zip', 'w') as myzip: myzip.write('eggs.txt')
python, official-docs, cpython, P0
Local_Trusted_Corpus
c3596dfe-e759-44ff-a7b0-3b8da337495f
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,570
supabase-export-v2
73299abe973e29bb
file-like object (``ZipExtFile``) is read-only and provides the following methods: :meth:`~io.BufferedIOBase.read`, :meth:`~io.IOBase.readline`, :meth:`~io.IOBase.readlines`, :meth:`~io.IOBase.seek`, :meth:`~io.IOBase.tell`, :meth:`~container.__iter__`, :meth:`~iterator.__next__`. These objects can operate independentl...
trusted_official_docs
CPython Docs
file-like object (``ZipExtFile``) is read-only and provides the following methods: :meth:`~io.BufferedIOBase.read`, :meth:`~io.IOBase.readline`, :meth:`~io.IOBase.readlines`, :meth:`~io.IOBase.seek`, :meth:`~io.IOBase.tell`, :meth:`~container.__iter__`, :meth:`~iterator.__next__`. These objects can operate independentl...
file-like object (``ZipExtFile``) is read-only and provides the following methods: :meth:`~io.BufferedIOBase.read`, :meth:`~io.IOBase.readline`, :meth:`~io.IOBase.readlines`, :meth:`~io.IOBase.seek`, :meth:`~io.IOBase.tell`, :meth:`~container.__iter__`, :meth:`~iterator.__next__`. These objects can operate independentl...
python, official-docs, cpython, P0
Local_Trusted_Corpus
c370829f-3941-4015-87a0-c419a8126eb7
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,612
supabase-export-v2
66dadb06eb07f674
A leading slash in the filename may lead to the archive being impossible to open in some zip programs on Windows systems. .. versionchanged:: 3.6 Calling :meth:`write` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
trusted_official_docs
CPython Docs
A leading slash in the filename may lead to the archive being impossible to open in some zip programs on Windows systems. .. versionchanged:: 3.6 Calling :meth:`write` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
A leading slash in the filename may lead to the archive being impossible to open in some zip programs on Windows systems. .. versionchanged:: 3.6 Calling :meth:`write` on a ZipFile created with mode ``'r'`` or a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised.
python, official-docs, cpython, P0
Local_Trusted_Corpus
c72b797d-193d-4124-994e-3bd6183da760
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,489
supabase-export-v2
b8adf9ca1ccb2d7f
append, and list a ZIP file. Any advanced use of this module will require an understanding of the format, as defined in `PKZIP Application Note`_. This module does not handle multipart ZIP files. It can handle ZIP files that use the ZIP64 extensions (that is ZIP files that are more than 4 GiB in size). It supports decr...
trusted_official_docs
CPython Docs
append, and list a ZIP file. Any advanced use of this module will require an understanding of the format, as defined in `PKZIP Application Note`_. This module does not handle multipart ZIP files. It can handle ZIP files that use the ZIP64 extensions (that is ZIP files that are more than 4 GiB in size). It supports decr...
append, and list a ZIP file. Any advanced use of this module will require an understanding of the format, as defined in `PKZIP Application Note`_. This module does not handle multipart ZIP files. It can handle ZIP files that use the ZIP64 extensions (that is ZIP files that are more than 4 GiB in size). It supports decr...
python, official-docs, cpython, P0
Local_Trusted_Corpus
c77fca33-465a-41be-bc26-60e2f4451805
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,528
supabase-export-v2
7edb607a3d58c8f3
.. note:: The ZIP file format specification has included support for bzip2 compression since 2001, for LZMA compression since 2006, and Zstandard compression since 2020. However, some tools (including older Python releases) do not support these compression methods, and may either refuse to process the ZIP file alto...
trusted_official_docs
CPython Docs
.. note:: The ZIP file format specification has included support for bzip2 compression since 2001, for LZMA compression since 2006, and Zstandard compression since 2020. However, some tools (including older Python releases) do not support these compression methods, and may either refuse to process the ZIP file alto...
.. note:: The ZIP file format specification has included support for bzip2 compression since 2001, for LZMA compression since 2006, and Zstandard compression since 2020. However, some tools (including older Python releases) do not support these compression methods, and may either refuse to process the ZIP file alto...
python, official-docs, cpython, P0
Local_Trusted_Corpus
c8e7e092-d67a-4973-af61-1d479db82e92
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,491
supabase-export-v2
2206186a67806268
.. The following paragraph should be similar to ../includes/optional-module.rst Handling compressed archives requires :term:`optional modules <optional module>` such as :mod:`zlib`, :mod:`bz2`, :mod:`lzma`, and :mod:`compression.zstd`. If any of them are missing from your copy of CPython, look for documentation from yo...
trusted_official_docs
CPython Docs
.. The following paragraph should be similar to ../includes/optional-module.rst Handling compressed archives requires :term:`optional modules <optional module>` such as :mod:`zlib`, :mod:`bz2`, :mod:`lzma`, and :mod:`compression.zstd`. If any of them are missing from your copy of CPython, look for documentation from yo...
.. The following paragraph should be similar to ../includes/optional-module.rst Handling compressed archives requires :term:`optional modules <optional module>` such as :mod:`zlib`, :mod:`bz2`, :mod:`lzma`, and :mod:`compression.zstd`. If any of them are missing from your copy of CPython, look for documentation from yo...
python, official-docs, cpython, P0
Local_Trusted_Corpus
c9d40af3-4fb3-4acd-bdac-012482a07b03
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,718
supabase-export-v2
5b314c62458416cf
The tuple contains: +-------+--------------------------+ | Index | Value | +=======+==========================+ | ``0`` | Year (>= 1980) | +-------+--------------------------+ | ``1`` | Month (one-based) | +-------+--------------------------+ | ``2`` | Day of month (one-based) | +-------+-----------------------...
trusted_official_docs
CPython Docs
The tuple contains: +-------+--------------------------+ | Index | Value | +=======+==========================+ | ``0`` | Year (>= 1980) | +-------+--------------------------+ | ``1`` | Month (one-based) | +-------+--------------------------+ | ``2`` | Day of month (one-based) | +-------+-----------------------...
The tuple contains: +-------+--------------------------+ | Index | Value | +=======+==========================+ | ``0`` | Year (>= 1980) | +-------+--------------------------+ | ``1`` | Month (one-based) | +-------+--------------------------+ | ``2`` | Day of month (one-based) | +-------+-----------------------...
python, official-docs, cpython, P0
Local_Trusted_Corpus
cb8b480a-3591-49d0-aa38-c5fe03ef986c
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,543
supabase-export-v2
a6833cb3b4bc80c7
and then :meth:`closed <close>` without adding any files to the archive, the appropriate ZIP structures for an empty archive will be written to the file. ZipFile is also a context manager and therefore supports the :keyword:`with` statement. In the example, *myzip* is closed after the :keyword:`!with` statement's sui...
trusted_official_docs
CPython Docs
and then :meth:`closed <close>` without adding any files to the archive, the appropriate ZIP structures for an empty archive will be written to the file. ZipFile is also a context manager and therefore supports the :keyword:`with` statement. In the example, *myzip* is closed after the :keyword:`!with` statement's sui...
and then :meth:`closed <close>` without adding any files to the archive, the appropriate ZIP structures for an empty archive will be written to the file. ZipFile is also a context manager and therefore supports the :keyword:`with` statement. In the example, *myzip* is closed after the :keyword:`!with` statement's sui...
python, official-docs, cpython, P0
Local_Trusted_Corpus
cfc7c679-f896-40df-bf88-c755184a698e
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,642
supabase-export-v2
77a3cacae2436eda
.. method:: Path.open(mode='r', *, pwd, **) Invoke :meth:`ZipFile.open` on the current path. Allows opening for read or write, text or binary through supported modes: 'r', 'w', 'rb', 'wb'. Positional and keyword arguments are passed through to :class:`io.TextIOWrapper` when opened as text and ignored otherwise. ``pw...
trusted_official_docs
CPython Docs
.. method:: Path.open(mode='r', *, pwd, **) Invoke :meth:`ZipFile.open` on the current path. Allows opening for read or write, text or binary through supported modes: 'r', 'w', 'rb', 'wb'. Positional and keyword arguments are passed through to :class:`io.TextIOWrapper` when opened as text and ignored otherwise. ``pw...
.. method:: Path.open(mode='r', *, pwd, **) Invoke :meth:`ZipFile.open` on the current path. Allows opening for read or write, text or binary through supported modes: 'r', 'w', 'rb', 'wb'. Positional and keyword arguments are passed through to :class:`io.TextIOWrapper` when opened as text and ignored otherwise. ``pw...
python, official-docs, cpython, P0
Local_Trusted_Corpus
d4395a4d-c23e-4bbb-8491-98ed0490ad98
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,562
supabase-export-v2
cd99f6d0221f3a2c
.. method:: ZipFile.infolist() Return a list containing a :class:`ZipInfo` object for each member of the archive. The objects are in the same order as their entries in the actual ZIP file on disk if an existing archive was opened.
trusted_official_docs
CPython Docs
.. method:: ZipFile.infolist() Return a list containing a :class:`ZipInfo` object for each member of the archive. The objects are in the same order as their entries in the actual ZIP file on disk if an existing archive was opened.
.. method:: ZipFile.infolist() Return a list containing a :class:`ZipInfo` object for each member of the archive. The objects are in the same order as their entries in the actual ZIP file on disk if an existing archive was opened.
python, official-docs, cpython, P0
Local_Trusted_Corpus
de365472-5756-468c-a1b4-d6c2f81869cc
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,579
supabase-export-v2
9d139cad683fd9a5
:attr:`!name` and :attr:`!mode` for the writeable file-like object. The value of the :attr:`!mode` attribute for the readable file-like object was changed from ``'r'`` to ``'rb'``. .. method:: ZipFile.extract(member, path=None, pwd=None)
trusted_official_docs
CPython Docs
:attr:`!name` and :attr:`!mode` for the writeable file-like object. The value of the :attr:`!mode` attribute for the readable file-like object was changed from ``'r'`` to ``'rb'``. .. method:: ZipFile.extract(member, path=None, pwd=None)
:attr:`!name` and :attr:`!mode` for the writeable file-like object. The value of the :attr:`!mode` attribute for the readable file-like object was changed from ``'r'`` to ``'rb'``. .. method:: ZipFile.extract(member, path=None, pwd=None)
python, official-docs, cpython, P0
Local_Trusted_Corpus
e1494b1d-7fe7-4f95-ab5f-5bbfca10069e
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,576
supabase-export-v2
a6cf9d95d57cca95
.. versionchanged:: 3.6 Removed support of ``mode='U'``. Use :class:`io.TextIOWrapper` for reading compressed text files in :term:`universal newlines` mode. .. versionchanged:: 3.6 :meth:`ZipFile.open` can now be used to write files into the archive with the ``mode='w'`` option.
trusted_official_docs
CPython Docs
.. versionchanged:: 3.6 Removed support of ``mode='U'``. Use :class:`io.TextIOWrapper` for reading compressed text files in :term:`universal newlines` mode. .. versionchanged:: 3.6 :meth:`ZipFile.open` can now be used to write files into the archive with the ``mode='w'`` option.
.. versionchanged:: 3.6 Removed support of ``mode='U'``. Use :class:`io.TextIOWrapper` for reading compressed text files in :term:`universal newlines` mode. .. versionchanged:: 3.6 :meth:`ZipFile.open` can now be used to write files into the archive with the ``mode='w'`` option.
python, official-docs, cpython, P0
Local_Trusted_Corpus
e2014f23-8587-4d89-beed-7b8d5ecaafe7
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,598
supabase-export-v2
1de469a5cb8426d5
than :const:`ZIP_STORED`, :const:`ZIP_DEFLATED`, :const:`ZIP_BZIP2`, :const:`ZIP_LZMA`, or :const:`ZIP_ZSTANDARD` will raise a :exc:`NotImplementedError`. An error will also be raised if the corresponding compression module is not available. .. versionchanged:: 3.6 Calling :meth:`read` on a closed ZipFile will raise a...
trusted_official_docs
CPython Docs
than :const:`ZIP_STORED`, :const:`ZIP_DEFLATED`, :const:`ZIP_BZIP2`, :const:`ZIP_LZMA`, or :const:`ZIP_ZSTANDARD` will raise a :exc:`NotImplementedError`. An error will also be raised if the corresponding compression module is not available. .. versionchanged:: 3.6 Calling :meth:`read` on a closed ZipFile will raise a...
than :const:`ZIP_STORED`, :const:`ZIP_DEFLATED`, :const:`ZIP_BZIP2`, :const:`ZIP_LZMA`, or :const:`ZIP_ZSTANDARD` will raise a :exc:`NotImplementedError`. An error will also be raised if the corresponding compression module is not available. .. versionchanged:: 3.6 Calling :meth:`read` on a closed ZipFile will raise a...
python, official-docs, cpython, P0
Local_Trusted_Corpus
e5043978-5677-4480-9d58-164efb9e9f6e
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,698
supabase-export-v2
04576a554c2f10e0
ZipInfo objects --------------- Instances of the :class:`ZipInfo` class are returned by the :meth:`.getinfo` and :meth:`.infolist` methods of :class:`ZipFile` objects. Each object stores information about a single member of the ZIP archive.
trusted_official_docs
CPython Docs
ZipInfo objects --------------- Instances of the :class:`ZipInfo` class are returned by the :meth:`.getinfo` and :meth:`.infolist` methods of :class:`ZipFile` objects. Each object stores information about a single member of the ZIP archive.
ZipInfo objects --------------- Instances of the :class:`ZipInfo` class are returned by the :meth:`.getinfo` and :meth:`.infolist` methods of :class:`ZipFile` objects. Each object stores information about a single member of the ZIP archive.
python, official-docs, cpython, P0
Local_Trusted_Corpus
eee1d59b-deab-463b-9911-480c2adceb68
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,569
supabase-export-v2
4c5ea197bcdf3473
with ZipFile('spam.zip') as myzip: with myzip.open('eggs.txt') as myfile: print(myfile.read()) With *mode* ``'r'`` the file-like object (``ZipExtFile``) is read-only and provides the following methods: :meth:`~io.BufferedIOBase.read`, :meth:`~io.IOBase.readline`, :meth:`~io.IOBase.readlines`, :meth:`~io.IOBase.seek`...
trusted_official_docs
CPython Docs
with ZipFile('spam.zip') as myzip: with myzip.open('eggs.txt') as myfile: print(myfile.read()) With *mode* ``'r'`` the file-like object (``ZipExtFile``) is read-only and provides the following methods: :meth:`~io.BufferedIOBase.read`, :meth:`~io.IOBase.readline`, :meth:`~io.IOBase.readlines`, :meth:`~io.IOBase.seek`...
with ZipFile('spam.zip') as myzip: with myzip.open('eggs.txt') as myfile: print(myfile.read()) With *mode* ``'r'`` the file-like object (``ZipExtFile``) is read-only and provides the following methods: :meth:`~io.BufferedIOBase.read`, :meth:`~io.IOBase.readline`, :meth:`~io.IOBase.readlines`, :meth:`~io.IOBase.seek`...
python, official-docs, cpython, P0
Local_Trusted_Corpus
f02fe429-78a5-45ac-828e-8ab3590f4a32
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,488
supabase-export-v2
b9a5144440fcb526
-------------- The ZIP file format is a common archive and compression standard. This module provides tools to create, read, write, append, and list a ZIP file. Any advanced use of this module will require an understanding of the format, as defined in `PKZIP Application Note`_.
trusted_official_docs
CPython Docs
-------------- The ZIP file format is a common archive and compression standard. This module provides tools to create, read, write, append, and list a ZIP file. Any advanced use of this module will require an understanding of the format, as defined in `PKZIP Application Note`_.
-------------- The ZIP file format is a common archive and compression standard. This module provides tools to create, read, write, append, and list a ZIP file. Any advanced use of this module will require an understanding of the format, as defined in `PKZIP Application Note`_.
python, official-docs, cpython, P0
Local_Trusted_Corpus
f0647482-b46b-4d5d-8396-aa6b333e0094
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,609
supabase-export-v2
dcb4e17ab66193d8
.. note:: If ``arcname`` (or ``filename``, if ``arcname`` is not given) contains a null byte, the name of the file in the archive will be truncated at the null byte.
trusted_official_docs
CPython Docs
.. note:: If ``arcname`` (or ``filename``, if ``arcname`` is not given) contains a null byte, the name of the file in the archive will be truncated at the null byte.
.. note:: If ``arcname`` (or ``filename``, if ``arcname`` is not given) contains a null byte, the name of the file in the archive will be truncated at the null byte.
python, official-docs, cpython, P0
Local_Trusted_Corpus
f4060b90-ec77-4add-a9ce-17bec80ec813
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,542
supabase-export-v2
97cdfd9dc859dfa6
may be set to the name of a codec, which will be used to decode metadata such as the names of members and ZIP comments. If the file is created with mode ``'w'``, ``'x'`` or ``'a'`` and then :meth:`closed <close>` without adding any files to the archive, the appropriate ZIP structures for an empty archive will be writ...
trusted_official_docs
CPython Docs
may be set to the name of a codec, which will be used to decode metadata such as the names of members and ZIP comments. If the file is created with mode ``'w'``, ``'x'`` or ``'a'`` and then :meth:`closed <close>` without adding any files to the archive, the appropriate ZIP structures for an empty archive will be writ...
may be set to the name of a codec, which will be used to decode metadata such as the names of members and ZIP comments. If the file is created with mode ``'w'``, ``'x'`` or ``'a'`` and then :meth:`closed <close>` without adding any files to the archive, the appropriate ZIP structures for an empty archive will be writ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
f5bf7400-7925-4218-9498-333649f37d90
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,623
supabase-export-v2
754a7ab2e5c6f5bb
the archive with the mode that is specified in the *mode* argument. If, however, *zinfo_or_directory* is a :class:`ZipInfo` instance then the *mode* argument is ignored. The archive must be opened with mode ``'w'``, ``'x'`` or ``'a'``.
trusted_official_docs
CPython Docs
the archive with the mode that is specified in the *mode* argument. If, however, *zinfo_or_directory* is a :class:`ZipInfo` instance then the *mode* argument is ignored. The archive must be opened with mode ``'w'``, ``'x'`` or ``'a'``.
the archive with the mode that is specified in the *mode* argument. If, however, *zinfo_or_directory* is a :class:`ZipInfo` instance then the *mode* argument is ignored. The archive must be opened with mode ``'w'``, ``'x'`` or ``'a'``.
python, official-docs, cpython, P0
Local_Trusted_Corpus
f65e57f2-090f-45c7-929e-2f41370cf66f
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,531
supabase-export-v2
78c5ce7fef51a178
`PKZIP Application Note`_ Documentation on the ZIP file format by Phil Katz, the creator of the format and algorithms used. `Info-ZIP Home Page <https://infozip.sourceforge.net/>`_ Information about the Info-ZIP project's ZIP archive programs and development libraries.
trusted_official_docs
CPython Docs
`PKZIP Application Note`_ Documentation on the ZIP file format by Phil Katz, the creator of the format and algorithms used. `Info-ZIP Home Page <https://infozip.sourceforge.net/>`_ Information about the Info-ZIP project's ZIP archive programs and development libraries.
`PKZIP Application Note`_ Documentation on the ZIP file format by Phil Katz, the creator of the format and algorithms used. `Info-ZIP Home Page <https://infozip.sourceforge.net/>`_ Information about the Info-ZIP project's ZIP archive programs and development libraries.
python, official-docs, cpython, P0
Local_Trusted_Corpus
f739dd12-ef1d-4f2b-b7a6-7b8feb369b4a
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,508
supabase-export-v2
a1558b340576d664
should be a tuple containing six fields which describe the time of the last modification to the file; the fields are described in section :ref:`zipinfo-objects`. .. versionchanged:: 3.13 A public :attr:`!compress_level` attribute has been added to expose the formerly protected :attr:`!_compresslevel`. The older prote...
trusted_official_docs
CPython Docs
should be a tuple containing six fields which describe the time of the last modification to the file; the fields are described in section :ref:`zipinfo-objects`. .. versionchanged:: 3.13 A public :attr:`!compress_level` attribute has been added to expose the formerly protected :attr:`!_compresslevel`. The older prote...
should be a tuple containing six fields which describe the time of the last modification to the file; the fields are described in section :ref:`zipinfo-objects`. .. versionchanged:: 3.13 A public :attr:`!compress_level` attribute has been added to expose the formerly protected :attr:`!_compresslevel`. The older prote...
python, official-docs, cpython, P0
Local_Trusted_Corpus
f7e3599f-8076-4607-aadd-b102d945a2f4
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,578
supabase-export-v2
ae939478e78208dc
.. versionchanged:: 3.6 Calling :meth:`.open` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised. .. versionchanged:: 3.13 Added attributes :attr:`!name` and :attr:`!mode` for the writeable file-like object. The value of the :attr:`!mode` attribute for the readable file-l...
trusted_official_docs
CPython Docs
.. versionchanged:: 3.6 Calling :meth:`.open` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised. .. versionchanged:: 3.13 Added attributes :attr:`!name` and :attr:`!mode` for the writeable file-like object. The value of the :attr:`!mode` attribute for the readable file-l...
.. versionchanged:: 3.6 Calling :meth:`.open` on a closed ZipFile will raise a :exc:`ValueError`. Previously, a :exc:`RuntimeError` was raised. .. versionchanged:: 3.13 Added attributes :attr:`!name` and :attr:`!mode` for the writeable file-like object. The value of the :attr:`!mode` attribute for the readable file-l...
python, official-docs, cpython, P0
Local_Trusted_Corpus
f83e4d2e-0788-4b33-91a1-f04d9365c139
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,618
supabase-export-v2
fe14e10275d74061
method used will be that specified in the *compress_type* member of the given :class:`ZipInfo` instance. By default, the :class:`ZipInfo` constructor sets this member to :const:`ZIP_STORED`. .. versionchanged:: 3.2 The *compress_type* argument.
trusted_official_docs
CPython Docs
method used will be that specified in the *compress_type* member of the given :class:`ZipInfo` instance. By default, the :class:`ZipInfo` constructor sets this member to :const:`ZIP_STORED`. .. versionchanged:: 3.2 The *compress_type* argument.
method used will be that specified in the *compress_type* member of the given :class:`ZipInfo` instance. By default, the :class:`ZipInfo` constructor sets this member to :const:`ZIP_STORED`. .. versionchanged:: 3.2 The *compress_type* argument.
python, official-docs, cpython, P0
Local_Trusted_Corpus
fa64d205-e9bf-4feb-8992-3bbed1465d13
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,541
supabase-export-v2
a449333e17ad0021
at the cost of setting the timestamp to 1980-01-01. Similar behavior occurs with files newer than 2107-12-31, the timestamp is also set to the limit. When mode is ``'r'``, *metadata_encoding* may be set to the name of a codec, which will be used to decode metadata such as the names of members and ZIP comments.
trusted_official_docs
CPython Docs
at the cost of setting the timestamp to 1980-01-01. Similar behavior occurs with files newer than 2107-12-31, the timestamp is also set to the limit. When mode is ``'r'``, *metadata_encoding* may be set to the name of a codec, which will be used to decode metadata such as the names of members and ZIP comments.
at the cost of setting the timestamp to 1980-01-01. Similar behavior occurs with files newer than 2107-12-31, the timestamp is also set to the limit. When mode is ``'r'``, *metadata_encoding* may be set to the name of a codec, which will be used to decode metadata such as the names of members and ZIP comments.
python, official-docs, cpython, P0
Local_Trusted_Corpus
fd1dc25f-1c78-40f0-8ade-82b86b20f855
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,547
supabase-export-v2
eb3564c4557c6241
*metadata_encoding* is an instance-wide setting for the ZipFile. It is not possible to set this on a per-member basis. This attribute is a workaround for legacy implementations which produce archives with names in the current locale encoding or code page (mostly on Windows). According to the .ZIP standard, the encodi...
trusted_official_docs
CPython Docs
*metadata_encoding* is an instance-wide setting for the ZipFile. It is not possible to set this on a per-member basis. This attribute is a workaround for legacy implementations which produce archives with names in the current locale encoding or code page (mostly on Windows). According to the .ZIP standard, the encodi...
*metadata_encoding* is an instance-wide setting for the ZipFile. It is not possible to set this on a per-member basis. This attribute is a workaround for legacy implementations which produce archives with names in the current locale encoding or code page (mostly on Windows). According to the .ZIP standard, the encodi...
python, official-docs, cpython, P0
Local_Trusted_Corpus
fff1b772-aad6-4279-97db-6d4bc1a54522
CPython Docs
file://datasets/cpython/Doc/library/zipfile.rst
unknown
c4ec3663-7be8-44a9-94ce-5bf7f8c7b8f5
12,637
supabase-export-v2
d38fd3b1803c28e5
vulnerabilities (e.g., filenames containing ".." or absolute paths). When handling untrusted archives, consider resolving filenames using :func:`os.path.abspath` and checking against the target directory with :func:`os.path.commonpath`. Path objects expose the following features of :mod:`pathlib.Path` objects:
trusted_official_docs
CPython Docs
vulnerabilities (e.g., filenames containing ".." or absolute paths). When handling untrusted archives, consider resolving filenames using :func:`os.path.abspath` and checking against the target directory with :func:`os.path.commonpath`. Path objects expose the following features of :mod:`pathlib.Path` objects:
vulnerabilities (e.g., filenames containing ".." or absolute paths). When handling untrusted archives, consider resolving filenames using :func:`os.path.abspath` and checking against the target directory with :func:`os.path.commonpath`. Path objects expose the following features of :mod:`pathlib.Path` objects:
python, official-docs, cpython, P0
Local_Trusted_Corpus
0ac6176f-0b03-420f-a860-42a9394b8661
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,803
supabase-export-v2
a4bade9cd8ac786f
With arguments, return a list of values that result from looking up each argument in the configuration variable dictionary. For each argument, if the value is not found, return ``None``.
trusted_official_docs
CPython Docs
With arguments, return a list of values that result from looking up each argument in the configuration variable dictionary. For each argument, if the value is not found, return ``None``.
With arguments, return a list of values that result from looking up each argument in the configuration variable dictionary. For each argument, if the value is not found, return ``None``.
python, official-docs, cpython, P0
Local_Trusted_Corpus
0b7e37bb-0763-45be-8404-e619f3883dbf
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,813
supabase-export-v2
ecf0ee377806677e
Python currently supports nine schemes: - *posix_prefix*: scheme for POSIX platforms like Linux or macOS. This is the default scheme used when Python or a component is installed. - *posix_home*: scheme for POSIX platforms, when the *home* option is used. This scheme defines paths located under a specific home prefix. ...
trusted_official_docs
CPython Docs
Python currently supports nine schemes: - *posix_prefix*: scheme for POSIX platforms like Linux or macOS. This is the default scheme used when Python or a component is installed. - *posix_home*: scheme for POSIX platforms, when the *home* option is used. This scheme defines paths located under a specific home prefix. ...
Python currently supports nine schemes: - *posix_prefix*: scheme for POSIX platforms like Linux or macOS. This is the default scheme used when Python or a component is installed. - *posix_home*: scheme for POSIX platforms, when the *home* option is used. This scheme defines paths located under a specific home prefix. ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
11460bf1-7ad5-4155-92db-029df58cbb7e
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,852
supabase-export-v2
1ad63d80fd07760d
*key* must be either ``"prefix"``, ``"home"``, or ``"user"``. The return value is a scheme name listed in :func:`get_scheme_names`. It can be passed to :mod:`!sysconfig` functions that take a *scheme* argument, such as :func:`get_paths`.
trusted_official_docs
CPython Docs
*key* must be either ``"prefix"``, ``"home"``, or ``"user"``. The return value is a scheme name listed in :func:`get_scheme_names`. It can be passed to :mod:`!sysconfig` functions that take a *scheme* argument, such as :func:`get_paths`.
*key* must be either ``"prefix"``, ``"home"``, or ``"user"``. The return value is a scheme name listed in :func:`get_scheme_names`. It can be passed to :mod:`!sysconfig` functions that take a *scheme* argument, such as :func:`get_paths`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
175030eb-6fad-41ad-955d-36f480d75589
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,873
supabase-export-v2
04b35cae7c6c8820
If *scheme* is not provided, will use the default scheme for the current platform. If *vars* is provided, it must be a dictionary of variables that will update the dictionary used to expand the paths.
trusted_official_docs
CPython Docs
If *scheme* is not provided, will use the default scheme for the current platform. If *vars* is provided, it must be a dictionary of variables that will update the dictionary used to expand the paths.
If *scheme* is not provided, will use the default scheme for the current platform. If *vars* is provided, it must be a dictionary of variables that will update the dictionary used to expand the paths.
python, official-docs, cpython, P0
Local_Trusted_Corpus
1d08e34f-f6fb-440b-85b5-a616866b47d8
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,834
supabase-export-v2
b6f00e07744cef1f
Prefix scheme ------------- The "prefix scheme" is useful when you wish to use one Python installation to perform the build/install (i.e., to run the setup script), but install modules into the third-party module directory of a different Python installation (or something that looks like a different Python installation)...
trusted_official_docs
CPython Docs
Prefix scheme ------------- The "prefix scheme" is useful when you wish to use one Python installation to perform the build/install (i.e., to run the setup script), but install modules into the third-party module directory of a different Python installation (or something that looks like a different Python installation)...
Prefix scheme ------------- The "prefix scheme" is useful when you wish to use one Python installation to perform the build/install (i.e., to run the setup script), but install modules into the third-party module directory of a different Python installation (or something that looks like a different Python installation)...
python, official-docs, cpython, P0
Local_Trusted_Corpus
279d6ed1-9aff-4c2f-8aa6-d548e4913aab
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,811
supabase-export-v2
b7bcdc1b8899fa1c
Installation paths ------------------ Python uses an installation scheme that differs depending on the platform and on the installation options. These schemes are stored in :mod:`!sysconfig` under unique identifiers based on the value returned by :const:`os.name`. The schemes are used by package installers to determine...
trusted_official_docs
CPython Docs
Installation paths ------------------ Python uses an installation scheme that differs depending on the platform and on the installation options. These schemes are stored in :mod:`!sysconfig` under unique identifiers based on the value returned by :const:`os.name`. The schemes are used by package installers to determine...
Installation paths ------------------ Python uses an installation scheme that differs depending on the platform and on the installation options. These schemes are stored in :mod:`!sysconfig` under unique identifiers based on the value returned by :const:`os.name`. The schemes are used by package installers to determine...
python, official-docs, cpython, P0
Local_Trusted_Corpus
3c92285a-a883-498d-bb31-a011b8e64318
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,815
supabase-export-v2
54177e74635fc055
with values from either *posix_venv* or *nt_venv* depending on the platform Python runs on. - *osx_framework_user*: scheme for macOS, when the *user* option is used. Each scheme is itself composed of a series of paths and each path has a unique identifier. Python currently uses eight paths:
trusted_official_docs
CPython Docs
with values from either *posix_venv* or *nt_venv* depending on the platform Python runs on. - *osx_framework_user*: scheme for macOS, when the *user* option is used. Each scheme is itself composed of a series of paths and each path has a unique identifier. Python currently uses eight paths:
with values from either *posix_venv* or *nt_venv* depending on the platform Python runs on. - *osx_framework_user*: scheme for macOS, when the *user* option is used. Each scheme is itself composed of a series of paths and each path has a unique identifier. Python currently uses eight paths:
python, official-docs, cpython, P0
Local_Trusted_Corpus
4b730522-9215-4305-9f10-163a7079b869
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,872
supabase-export-v2
921a5223bc022183
Return a dictionary containing all installation paths corresponding to an installation scheme. See :func:`get_path` for more information. If *scheme* is not provided, will use the default scheme for the current platform.
trusted_official_docs
CPython Docs
Return a dictionary containing all installation paths corresponding to an installation scheme. See :func:`get_path` for more information. If *scheme* is not provided, will use the default scheme for the current platform.
Return a dictionary containing all installation paths corresponding to an installation scheme. See :func:`get_path` for more information. If *scheme* is not provided, will use the default scheme for the current platform.
python, official-docs, cpython, P0
Local_Trusted_Corpus
52ab64c3-4768-468c-ab6f-9051f4dfeb9b
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,836
supabase-export-v2
71c91fe3004911b4
rather than a local add-on. However, if you are installing Python modules from source, you probably want them to go in :file:`/usr/local/lib/python2.{X}` rather than :file:`/usr/lib/python2.{X}`. Another possibility is a network filesystem where the name used to write to a remote directory is different from the name us...
trusted_official_docs
CPython Docs
rather than a local add-on. However, if you are installing Python modules from source, you probably want them to go in :file:`/usr/local/lib/python2.{X}` rather than :file:`/usr/lib/python2.{X}`. Another possibility is a network filesystem where the name used to write to a remote directory is different from the name us...
rather than a local add-on. However, if you are installing Python modules from source, you probably want them to go in :file:`/usr/local/lib/python2.{X}` rather than :file:`/usr/lib/python2.{X}`. Another possibility is a network filesystem where the name used to write to a remote directory is different from the name us...
python, official-docs, cpython, P0
Local_Trusted_Corpus
56971376-e19f-49bb-a0c9-c13ac48a5f29
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,802
supabase-export-v2
5fbd36b4db6079f5
With no arguments, return a dictionary of all configuration variables relevant for the current platform. With arguments, return a list of values that result from looking up each argument in the configuration variable dictionary.
trusted_official_docs
CPython Docs
With no arguments, return a dictionary of all configuration variables relevant for the current platform. With arguments, return a list of values that result from looking up each argument in the configuration variable dictionary.
With no arguments, return a dictionary of all configuration variables relevant for the current platform. With arguments, return a list of values that result from looking up each argument in the configuration variable dictionary.
python, official-docs, cpython, P0
Local_Trusted_Corpus
5c59b6b5-a2d4-4666-8265-17ec968e6767
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,814
supabase-export-v2
21e68d293fb9b5e1
Windows, when the *user* option is used. - *nt_venv*: scheme for :mod:`Python virtual environments <venv>` on Windows; by default it is the same as *nt*. - *venv*: a scheme with values from either *posix_venv* or *nt_venv* depending on the platform Python runs on. - *osx_framework_user*: scheme for macOS, when the *us...
trusted_official_docs
CPython Docs
Windows, when the *user* option is used. - *nt_venv*: scheme for :mod:`Python virtual environments <venv>` on Windows; by default it is the same as *nt*. - *venv*: a scheme with values from either *posix_venv* or *nt_venv* depending on the platform Python runs on. - *osx_framework_user*: scheme for macOS, when the *us...
Windows, when the *user* option is used. - *nt_venv*: scheme for :mod:`Python virtual environments <venv>` on Windows; by default it is the same as *nt*. - *venv*: a scheme with values from either *posix_venv* or *nt_venv* depending on the platform Python runs on. - *osx_framework_user*: scheme for macOS, when the *us...
python, official-docs, cpython, P0
Local_Trusted_Corpus
60c2a730-3b9f-4de2-ab76-224687a497a5
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,820
supabase-export-v2
de4dba7c33e7a78a
to be the most convenient solution for users that don't have write permission to the global site-packages directory or don't want to install into it. Files will be installed into subdirectories of :const:`site.USER_BASE` (written as :file:`{userbase}` hereafter). This scheme installs pure Python modules and extension m...
trusted_official_docs
CPython Docs
to be the most convenient solution for users that don't have write permission to the global site-packages directory or don't want to install into it. Files will be installed into subdirectories of :const:`site.USER_BASE` (written as :file:`{userbase}` hereafter). This scheme installs pure Python modules and extension m...
to be the most convenient solution for users that don't have write permission to the global site-packages directory or don't want to install into it. Files will be installed into subdirectories of :const:`site.USER_BASE` (written as :file:`{userbase}` hereafter). This scheme installs pure Python modules and extension m...
python, official-docs, cpython, P0
Local_Trusted_Corpus
60e0dbb2-be13-4378-a723-7b5ea5d3bc83
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,865
supabase-export-v2
e7d13c52e2c9737b
paths corresponding to each path name, for each platform, with variables to be expanded. For instance the *stdlib* path for the *nt* scheme is: ``{base}/Lib``. :func:`get_path` will use the variables returned by :func:`get_config_vars` to expand the path. All variables have default values for each platform so one may...
trusted_official_docs
CPython Docs
paths corresponding to each path name, for each platform, with variables to be expanded. For instance the *stdlib* path for the *nt* scheme is: ``{base}/Lib``. :func:`get_path` will use the variables returned by :func:`get_config_vars` to expand the path. All variables have default values for each platform so one may...
paths corresponding to each path name, for each platform, with variables to be expanded. For instance the *stdlib* path for the *nt* scheme is: ``{base}/Lib``. :func:`get_path` will use the variables returned by :func:`get_config_vars` to expand the path. All variables have default values for each platform so one may...
python, official-docs, cpython, P0
Local_Trusted_Corpus
6c56aedd-de06-482a-b02e-350ad76346e4
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,881
supabase-export-v2
ef59f6ebe9535c03
Return a string that identifies the current platform. This is used mainly to distinguish platform-specific build directories and platform-specific built distributions. Typically includes the OS name and version and the architecture (as supplied by :func:`os.uname`), although the exact information included depends on...
trusted_official_docs
CPython Docs
Return a string that identifies the current platform. This is used mainly to distinguish platform-specific build directories and platform-specific built distributions. Typically includes the OS name and version and the architecture (as supplied by :func:`os.uname`), although the exact information included depends on...
Return a string that identifies the current platform. This is used mainly to distinguish platform-specific build directories and platform-specific built distributions. Typically includes the OS name and version and the architecture (as supplied by :func:`os.uname`), although the exact information included depends on...
python, official-docs, cpython, P0
Local_Trusted_Corpus
6f6478b2-6057-40fe-8478-0a712cab7eb3
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,867
supabase-export-v2
1c51e079c4c8466a
If *scheme* is provided, it must be a value from the list returned by :func:`get_scheme_names`. Otherwise, the default scheme for the current platform is used. If *vars* is provided, it must be a dictionary of variables that will update the dictionary returned by :func:`get_config_vars`.
trusted_official_docs
CPython Docs
If *scheme* is provided, it must be a value from the list returned by :func:`get_scheme_names`. Otherwise, the default scheme for the current platform is used. If *vars* is provided, it must be a dictionary of variables that will update the dictionary returned by :func:`get_config_vars`.
If *scheme* is provided, it must be a value from the list returned by :func:`get_scheme_names`. Otherwise, the default scheme for the current platform is used. If *vars* is provided, it must be a dictionary of variables that will update the dictionary returned by :func:`get_config_vars`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
83a36643-6734-4231-9c90-172c4f6350c9
CPython Docs
file://datasets/cpython/Doc/library/sysconfig.rst
unknown
2e7d75b2-9f0f-4f3e-8911-4e72bf97e213
12,890
supabase-export-v2
af0cb4ed71d46010
.. function:: is_python_build() Return ``True`` if the running Python interpreter was built from source and is being run from its built location, and not from a location resulting from e.g. running ``make install`` or installing via a binary installer.
trusted_official_docs
CPython Docs
.. function:: is_python_build() Return ``True`` if the running Python interpreter was built from source and is being run from its built location, and not from a location resulting from e.g. running ``make install`` or installing via a binary installer.
.. function:: is_python_build() Return ``True`` if the running Python interpreter was built from source and is being run from its built location, and not from a location resulting from e.g. running ``make install`` or installing via a binary installer.
python, official-docs, cpython, P0
Local_Trusted_Corpus