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
bc5ae161-85f2-4501-a09b-7274f94e1d3a
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
46,938
supabase-export-v2
c1a1f5ea951cebe3
| +------------------+---------------------------------------------+ | ``'x:gz'`` | Create a tarfile with gzip compression. | | | Raise a :exc:`FileExistsError` exception | | | if it already exists. | +------------------+---------------------------------------------+ | ``'x:bz2'`` | Create a tarfile with bzip2 compre...
trusted_official_docs
CPython Docs
| +------------------+---------------------------------------------+ | ``'x:gz'`` | Create a tarfile with gzip compression. | | | Raise a :exc:`FileExistsError` exception | | | if it already exists. | +------------------+---------------------------------------------+ | ``'x:bz2'`` | Create a tarfile with bzip2 compre...
| +------------------+---------------------------------------------+ | ``'x:gz'`` | Create a tarfile with gzip compression. | | | Raise a :exc:`FileExistsError` exception | | | if it already exists. | +------------------+---------------------------------------------+ | ``'x:bz2'`` | Create a tarfile with bzip2 compre...
python, official-docs, cpython, P0
Local_Trusted_Corpus
c147fca5-db8b-42e4-b7e5-61d85396b6a0
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
46,942
supabase-export-v2
c780cf8122f30e30
a certain (compressed) file for reading, :exc:`ReadError` is raised. Use *mode* ``'r'`` to avoid this. If a compression method is not supported, :exc:`CompressionError` is raised. If *fileobj* is specified, it is used as an alternative to a :term:`file object` opened in binary mode for *name*. It is supposed to be at ...
trusted_official_docs
CPython Docs
a certain (compressed) file for reading, :exc:`ReadError` is raised. Use *mode* ``'r'`` to avoid this. If a compression method is not supported, :exc:`CompressionError` is raised. If *fileobj* is specified, it is used as an alternative to a :term:`file object` opened in binary mode for *name*. It is supposed to be at ...
a certain (compressed) file for reading, :exc:`ReadError` is raised. Use *mode* ``'r'`` to avoid this. If a compression method is not supported, :exc:`CompressionError` is raised. If *fileobj* is specified, it is used as an alternative to a :term:`file object` opened in binary mode for *name*. It is supposed to be at ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
c4f85782-6b16-4ae9-85c7-d9cd713c0e70
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
46,944
supabase-export-v2
a036298f29777df0
For modes ``'w:gz'``, ``'x:gz'``, ``'w|gz'``, ``'w:bz2'``, ``'x:bz2'``, ``'w|bz2'``, :func:`tarfile.open` accepts the keyword argument *compresslevel* (default ``6``) to specify the compression level of the file. For modes ``'w:xz'``, ``'x:xz'`` and ``'w|xz'``, :func:`tarfile.open` accepts the keyword argument *preset...
trusted_official_docs
CPython Docs
For modes ``'w:gz'``, ``'x:gz'``, ``'w|gz'``, ``'w:bz2'``, ``'x:bz2'``, ``'w|bz2'``, :func:`tarfile.open` accepts the keyword argument *compresslevel* (default ``6``) to specify the compression level of the file. For modes ``'w:xz'``, ``'x:xz'`` and ``'w|xz'``, :func:`tarfile.open` accepts the keyword argument *preset...
For modes ``'w:gz'``, ``'x:gz'``, ``'w|gz'``, ``'w:bz2'``, ``'x:bz2'``, ``'w|bz2'``, :func:`tarfile.open` accepts the keyword argument *compresslevel* (default ``6``) to specify the compression level of the file. For modes ``'w:xz'``, ``'x:xz'`` and ``'w|xz'``, :func:`tarfile.open` accepts the keyword argument *preset...
python, official-docs, cpython, P0
Local_Trusted_Corpus
c6d11629-debc-41b7-a4f2-2c8fe935c41e
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,335
supabase-export-v2
10d14d0ac71147b6
There are three tar formats that can be created with the :mod:`!tarfile` module: * The POSIX.1-1988 ustar format (:const:`USTAR_FORMAT`). It supports filenames up to a length of at best 256 characters and linknames up to 100 characters. The maximum file size is 8 GiB. This is an old and limited but widely supported f...
trusted_official_docs
CPython Docs
There are three tar formats that can be created with the :mod:`!tarfile` module: * The POSIX.1-1988 ustar format (:const:`USTAR_FORMAT`). It supports filenames up to a length of at best 256 characters and linknames up to 100 characters. The maximum file size is 8 GiB. This is an old and limited but widely supported f...
There are three tar formats that can be created with the :mod:`!tarfile` module: * The POSIX.1-1988 ustar format (:const:`USTAR_FORMAT`). It supports filenames up to a length of at best 256 characters and linknames up to 100 characters. The maximum file size is 8 GiB. This is an old and limited but widely supported f...
python, official-docs, cpython, P0
Local_Trusted_Corpus
ca235846-3ca4-452b-9ffc-d0b07662bde6
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,227
supabase-export-v2
33ee4d476cb3386a
filter(member: TarInfo, path: str, /) -> TarInfo | None The callable is called just before each member is extracted, so it can take the current state of the disk into account. It can:
trusted_official_docs
CPython Docs
filter(member: TarInfo, path: str, /) -> TarInfo | None The callable is called just before each member is extracted, so it can take the current state of the disk into account. It can:
filter(member: TarInfo, path: str, /) -> TarInfo | None The callable is called just before each member is extracted, so it can take the current state of the disk into account. It can:
python, official-docs, cpython, P0
Local_Trusted_Corpus
cafb1675-92db-4a59-8f07-37cfc3911a16
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
46,919
supabase-export-v2
e87a905168c12a3c
-------------- The :mod:`!tarfile` module makes it possible to read and write tar archives, including those using gzip, bz2 and lzma compression. Use the :mod:`zipfile` module to read or write :file:`.zip` files, or the higher-level functions in :ref:`shutil <archiving-operations>`.
trusted_official_docs
CPython Docs
-------------- The :mod:`!tarfile` module makes it possible to read and write tar archives, including those using gzip, bz2 and lzma compression. Use the :mod:`zipfile` module to read or write :file:`.zip` files, or the higher-level functions in :ref:`shutil <archiving-operations>`.
-------------- The :mod:`!tarfile` module makes it possible to read and write tar archives, including those using gzip, bz2 and lzma compression. Use the :mod:`zipfile` module to read or write :file:`.zip` files, or the higher-level functions in :ref:`shutil <archiving-operations>`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
cb5a555d-9653-4064-9650-31c2208f6523
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,079
supabase-export-v2
db2e49f50d346973
You can specify a different directory using *path*. *path* may be a :term:`path-like object`. File attributes (owner, mtime, mode) are set unless *set_attrs* is false. The *numeric_owner* and *filter* arguments are the same as for :meth:`extractall`.
trusted_official_docs
CPython Docs
You can specify a different directory using *path*. *path* may be a :term:`path-like object`. File attributes (owner, mtime, mode) are set unless *set_attrs* is false. The *numeric_owner* and *filter* arguments are the same as for :meth:`extractall`.
You can specify a different directory using *path*. *path* may be a :term:`path-like object`. File attributes (owner, mtime, mode) are set unless *set_attrs* is false. The *numeric_owner* and *filter* arguments are the same as for :meth:`extractall`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
cb6e1bdb-208b-4782-8444-85392759bad3
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,248
supabase-export-v2
745fb3c5268ce07d
extraction methods skip applying permission bits. - Set user and group info (``uid``, ``gid``, ``uname``, ``gname``) to ``None``, so that extraction methods skip setting it. Return the modified ``TarInfo`` member.
trusted_official_docs
CPython Docs
extraction methods skip applying permission bits. - Set user and group info (``uid``, ``gid``, ``uname``, ``gname``) to ``None``, so that extraction methods skip setting it. Return the modified ``TarInfo`` member.
extraction methods skip applying permission bits. - Set user and group info (``uid``, ``gid``, ``uname``, ``gname``) to ``None``, so that extraction methods skip setting it. Return the modified ``TarInfo`` member.
python, official-docs, cpython, P0
Local_Trusted_Corpus
cb7301e5-81ee-46bf-b4ad-312717c081af
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
46,989
supabase-export-v2
710a5a0d32b1eb0e
.. exception:: LinkFallbackError Raised to refuse emulating a link (hard or symbolic) by extracting another archive member, when that member would be rejected by the filter location. The exception that was raised to reject the replacement member is available as :attr:`!BaseException.__context__`.
trusted_official_docs
CPython Docs
.. exception:: LinkFallbackError Raised to refuse emulating a link (hard or symbolic) by extracting another archive member, when that member would be rejected by the filter location. The exception that was raised to reject the replacement member is available as :attr:`!BaseException.__context__`.
.. exception:: LinkFallbackError Raised to refuse emulating a link (hard or symbolic) by extracting another archive member, when that member would be rejected by the filter location. The exception that was raised to reject the replacement member is available as :attr:`!BaseException.__context__`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
d01dd953-87ce-4f5c-a3cb-1b143e0264d0
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
46,946
supabase-export-v2
358ea52a41ab5652
by :class:`~compression.zstd.CompressionParameter`. The keyword argument *zstd_dict* can be passed to provide a :class:`~compression.zstd.ZstdDict`, a Zstandard dictionary used to improve compression of smaller amounts of data. For modes ``'w:gz'`` and ``'w|gz'``, :func:`tarfile.open` accepts the keyword argument *mti...
trusted_official_docs
CPython Docs
by :class:`~compression.zstd.CompressionParameter`. The keyword argument *zstd_dict* can be passed to provide a :class:`~compression.zstd.ZstdDict`, a Zstandard dictionary used to improve compression of smaller amounts of data. For modes ``'w:gz'`` and ``'w|gz'``, :func:`tarfile.open` accepts the keyword argument *mti...
by :class:`~compression.zstd.CompressionParameter`. The keyword argument *zstd_dict* can be passed to provide a :class:`~compression.zstd.ZstdDict`, a Zstandard dictionary used to improve compression of smaller amounts of data. For modes ``'w:gz'`` and ``'w|gz'``, :func:`tarfile.open` accepts the keyword argument *mti...
python, official-docs, cpython, P0
Local_Trusted_Corpus
d37a41df-4cef-45a2-904d-4b75204146bf
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,125
supabase-export-v2
855cea65e9d0ba5b
:class:`TarInfo` objects are returned by :class:`TarFile`'s methods :meth:`~TarFile.getmember`, :meth:`~TarFile.getmembers` and :meth:`~TarFile.gettarinfo`. Modifying the objects returned by :meth:`~TarFile.getmember` or :meth:`~TarFile.getmembers` will affect all subsequent operations on the archive. For cases where t...
trusted_official_docs
CPython Docs
:class:`TarInfo` objects are returned by :class:`TarFile`'s methods :meth:`~TarFile.getmember`, :meth:`~TarFile.getmembers` and :meth:`~TarFile.gettarinfo`. Modifying the objects returned by :meth:`~TarFile.getmember` or :meth:`~TarFile.getmembers` will affect all subsequent operations on the archive. For cases where t...
:class:`TarInfo` objects are returned by :class:`TarFile`'s methods :meth:`~TarFile.getmember`, :meth:`~TarFile.getmembers` and :meth:`~TarFile.gettarinfo`. Modifying the objects returned by :meth:`~TarFile.getmember` or :meth:`~TarFile.getmembers` will affect all subsequent operations on the archive. For cases where t...
python, official-docs, cpython, P0
Local_Trusted_Corpus
d3adf8e3-2c4c-4675-828b-44a86dfa7b17
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,104
supabase-export-v2
7f750dd69cb38fe6
.. versionchanged:: 3.14 The default filter is set to :func:`data <data_filter>`, which disallows some dangerous features such as links to absolute paths or paths outside of the destination. Previously, the default was equivalent to :func:`fully_trusted <fully_trusted_filter>`.
trusted_official_docs
CPython Docs
.. versionchanged:: 3.14 The default filter is set to :func:`data <data_filter>`, which disallows some dangerous features such as links to absolute paths or paths outside of the destination. Previously, the default was equivalent to :func:`fully_trusted <fully_trusted_filter>`.
.. versionchanged:: 3.14 The default filter is set to :func:`data <data_filter>`, which disallows some dangerous features such as links to absolute paths or paths outside of the destination. Previously, the default was equivalent to :func:`fully_trusted <fully_trusted_filter>`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
d43f23c7-d9a2-4cfa-a594-1ad0b9ff7437
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,033
supabase-export-v2
8339f69320c29ed7
All following arguments are optional and can be accessed as instance attributes as well. *name* is the pathname of the archive. *name* may be a :term:`path-like object`. It can be omitted if *fileobj* is given. In this case, the file object's :attr:`!name` attribute is used if it exists.
trusted_official_docs
CPython Docs
All following arguments are optional and can be accessed as instance attributes as well. *name* is the pathname of the archive. *name* may be a :term:`path-like object`. It can be omitted if *fileobj* is given. In this case, the file object's :attr:`!name` attribute is used if it exists.
All following arguments are optional and can be accessed as instance attributes as well. *name* is the pathname of the archive. *name* may be a :term:`path-like object`. It can be omitted if *fileobj* is given. In this case, the file object's :attr:`!name` attribute is used if it exists.
python, official-docs, cpython, P0
Local_Trusted_Corpus
d46b27ed-96b9-4829-8f09-7f7ca9d65cb5
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,262
supabase-export-v2
a06a81c0a3a62cc4
does not protect against issues with “live” data, e.g. an attacker tinkering with the destination (or source) directory while extraction (or archiving) is in progress. Supporting older Python versions ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
trusted_official_docs
CPython Docs
does not protect against issues with “live” data, e.g. an attacker tinkering with the destination (or source) directory while extraction (or archiving) is in progress. Supporting older Python versions ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
does not protect against issues with “live” data, e.g. an attacker tinkering with the destination (or source) directory while extraction (or archiving) is in progress. Supporting older Python versions ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
python, official-docs, cpython, P0
Local_Trusted_Corpus
d4c5a74b-ec28-4975-9edb-3b8ab7a74de5
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,089
supabase-export-v2
3fdfe116f3b323c3
.. method:: TarFile.extractfile(member) Extract a member from the archive as a file object. *member* may be a filename or a :class:`TarInfo` object. If *member* is a regular file or a link, an :class:`io.BufferedReader` object is returned. For all other existing members, :const:`None` is returned. If *member* does n...
trusted_official_docs
CPython Docs
.. method:: TarFile.extractfile(member) Extract a member from the archive as a file object. *member* may be a filename or a :class:`TarInfo` object. If *member* is a regular file or a link, an :class:`io.BufferedReader` object is returned. For all other existing members, :const:`None` is returned. If *member* does n...
.. method:: TarFile.extractfile(member) Extract a member from the archive as a file object. *member* may be a filename or a :class:`TarInfo` object. If *member* is a regular file or a link, an :class:`io.BufferedReader` object is returned. For all other existing members, :const:`None` is returned. If *member* does n...
python, official-docs, cpython, P0
Local_Trusted_Corpus
d63c3496-d2e5-4d75-890d-29ad308ff3a2
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,043
supabase-export-v2
f39b70b7aa364d37
*debug* can be set from ``0`` (no debug messages) up to ``3`` (all debug messages). The messages are written to ``sys.stderr``. *errorlevel* controls how extraction errors are handled, see :attr:`the corresponding attribute <TarFile.errorlevel>`.
trusted_official_docs
CPython Docs
*debug* can be set from ``0`` (no debug messages) up to ``3`` (all debug messages). The messages are written to ``sys.stderr``. *errorlevel* controls how extraction errors are handled, see :attr:`the corresponding attribute <TarFile.errorlevel>`.
*debug* can be set from ``0`` (no debug messages) up to ``3`` (all debug messages). The messages are written to ``sys.stderr``. *errorlevel* controls how extraction errors are handled, see :attr:`the corresponding attribute <TarFile.errorlevel>`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
d8e156ef-fb6c-45f9-a826-eee481290a92
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,072
supabase-export-v2
e76ca9fc4fe23587
Never extract archives from untrusted sources without prior inspection. Since Python 3.14, the default (:func:`data <data_filter>`) will prevent the most dangerous security issues. However, it will not prevent *all* unintended or insecure behavior. Read the :ref:`tarfile-extraction-filter` section for details.
trusted_official_docs
CPython Docs
Never extract archives from untrusted sources without prior inspection. Since Python 3.14, the default (:func:`data <data_filter>`) will prevent the most dangerous security issues. However, it will not prevent *all* unintended or insecure behavior. Read the :ref:`tarfile-extraction-filter` section for details.
Never extract archives from untrusted sources without prior inspection. Since Python 3.14, the default (:func:`data <data_filter>`) will prevent the most dangerous security issues. However, it will not prevent *all* unintended or insecure behavior. Read the :ref:`tarfile-extraction-filter` section for details.
python, official-docs, cpython, P0
Local_Trusted_Corpus
d93e9f4b-2e88-4418-b38a-b24d7dde7a50
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,093
supabase-export-v2
47a18e2f1a4c9a36
.. attribute:: TarFile.errorlevel :type: int If *errorlevel* is ``0``, errors are ignored when using :meth:`TarFile.extract` and :meth:`TarFile.extractall`. Nevertheless, they appear as error messages in the debug output when *debug* is greater than 0. If ``1`` (the default), all *fatal* errors are raised as :exc:`OS...
trusted_official_docs
CPython Docs
.. attribute:: TarFile.errorlevel :type: int If *errorlevel* is ``0``, errors are ignored when using :meth:`TarFile.extract` and :meth:`TarFile.extractall`. Nevertheless, they appear as error messages in the debug output when *debug* is greater than 0. If ``1`` (the default), all *fatal* errors are raised as :exc:`OS...
.. attribute:: TarFile.errorlevel :type: int If *errorlevel* is ``0``, errors are ignored when using :meth:`TarFile.extract` and :meth:`TarFile.extractall`. Nevertheless, they appear as error messages in the debug output when *debug* is greater than 0. If ``1`` (the default), all *fatal* errors are raised as :exc:`OS...
python, official-docs, cpython, P0
Local_Trusted_Corpus
e0a43264-7b28-4536-bd7e-697a87afea7e
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,069
supabase-export-v2
446445c3a4a2dba6
and gid numbers from the tarfile are used to set the owner/group for the extracted files. Otherwise, the named values from the tarfile are used. The *filter* argument specifies how ``members`` are modified or rejected before extraction. See :ref:`tarfile-extraction-filter` for details. It is recommended to set this ex...
trusted_official_docs
CPython Docs
and gid numbers from the tarfile are used to set the owner/group for the extracted files. Otherwise, the named values from the tarfile are used. The *filter* argument specifies how ``members`` are modified or rejected before extraction. See :ref:`tarfile-extraction-filter` for details. It is recommended to set this ex...
and gid numbers from the tarfile are used to set the owner/group for the extracted files. Otherwise, the named values from the tarfile are used. The *filter* argument specifies how ``members`` are modified or rejected before extraction. See :ref:`tarfile-extraction-filter` for details. It is recommended to set this ex...
python, official-docs, cpython, P0
Local_Trusted_Corpus
e359f798-9842-47eb-bbdd-451234af85bb
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,337
supabase-export-v2
8c26a3b6af49b481
files. It is the de facto standard on GNU/Linux systems. :mod:`!tarfile` fully supports the GNU tar extensions for long names, sparse file support is read-only. * The POSIX.1-2001 pax format (:const:`PAX_FORMAT`). It is the most flexible format with virtually no limits. It supports long filenames and linknames, large ...
trusted_official_docs
CPython Docs
files. It is the de facto standard on GNU/Linux systems. :mod:`!tarfile` fully supports the GNU tar extensions for long names, sparse file support is read-only. * The POSIX.1-2001 pax format (:const:`PAX_FORMAT`). It is the most flexible format with virtually no limits. It supports long filenames and linknames, large ...
files. It is the de facto standard on GNU/Linux systems. :mod:`!tarfile` fully supports the GNU tar extensions for long names, sparse file support is read-only. * The POSIX.1-2001 pax format (:const:`PAX_FORMAT`). It is the most flexible format with virtually no limits. It supports long filenames and linknames, large ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
e380de68-b292-496a-b97c-90c5c325bd5f
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
46,928
supabase-export-v2
9114df69497cb90e
files, hardlinks, symbolic links, fifos, character devices and block devices and is able to acquire and restore file information like timestamp, access permissions and owner. .. versionchanged:: 3.3 Added support for :mod:`lzma` compression.
trusted_official_docs
CPython Docs
files, hardlinks, symbolic links, fifos, character devices and block devices and is able to acquire and restore file information like timestamp, access permissions and owner. .. versionchanged:: 3.3 Added support for :mod:`lzma` compression.
files, hardlinks, symbolic links, fifos, character devices and block devices and is able to acquire and restore file information like timestamp, access permissions and owner. .. versionchanged:: 3.3 Added support for :mod:`lzma` compression.
python, official-docs, cpython, P0
Local_Trusted_Corpus
e414f624-1ab0-4022-b97b-15b743dfa763
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,029
supabase-export-v2
81f32b01743d9844
is possible to store a file in a tar archive several times. Each archive member is represented by a :class:`TarInfo` object, see :ref:`tarinfo-objects` for details. A :class:`TarFile` object can be used as a context manager in a :keyword:`with` statement. It will automatically be closed when the block is completed. Ple...
trusted_official_docs
CPython Docs
is possible to store a file in a tar archive several times. Each archive member is represented by a :class:`TarInfo` object, see :ref:`tarinfo-objects` for details. A :class:`TarFile` object can be used as a context manager in a :keyword:`with` statement. It will automatically be closed when the block is completed. Ple...
is possible to store a file in a tar archive several times. Each archive member is represented by a :class:`TarInfo` object, see :ref:`tarinfo-objects` for details. A :class:`TarFile` object can be used as a context manager in a :keyword:`with` statement. It will automatically be closed when the block is completed. Ple...
python, official-docs, cpython, P0
Local_Trusted_Corpus
e470fe69-5a92-4d08-9eea-fbcc0bf9e210
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,078
supabase-export-v2
628eeebbb8094dc2
.. method:: TarFile.extract(member, path="", set_attrs=True, *, numeric_owner=False, filter=None) Extract a member from the archive to the current working directory, using its full name. Its file information is extracted as accurately as possible. *member* may be a filename or a :class:`TarInfo` object. You can speci...
trusted_official_docs
CPython Docs
.. method:: TarFile.extract(member, path="", set_attrs=True, *, numeric_owner=False, filter=None) Extract a member from the archive to the current working directory, using its full name. Its file information is extracted as accurately as possible. *member* may be a filename or a :class:`TarInfo` object. You can speci...
.. method:: TarFile.extract(member, path="", set_attrs=True, *, numeric_owner=False, filter=None) Extract a member from the archive to the current working directory, using its full name. Its file information is extracted as accurately as possible. *member* may be a filename or a :class:`TarInfo` object. You can speci...
python, official-docs, cpython, P0
Local_Trusted_Corpus
e4821c97-bd8e-4016-afc2-07d0bef543f2
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,073
supabase-export-v2
a3e8ecc0a1a9f670
(:func:`data <data_filter>`) will prevent the most dangerous security issues. However, it will not prevent *all* unintended or insecure behavior. Read the :ref:`tarfile-extraction-filter` section for details. .. versionchanged:: 3.5 Added the *numeric_owner* parameter.
trusted_official_docs
CPython Docs
(:func:`data <data_filter>`) will prevent the most dangerous security issues. However, it will not prevent *all* unintended or insecure behavior. Read the :ref:`tarfile-extraction-filter` section for details. .. versionchanged:: 3.5 Added the *numeric_owner* parameter.
(:func:`data <data_filter>`) will prevent the most dangerous security issues. However, it will not prevent *all* unintended or insecure behavior. Read the :ref:`tarfile-extraction-filter` section for details. .. versionchanged:: 3.5 Added the *numeric_owner* parameter.
python, official-docs, cpython, P0
Local_Trusted_Corpus
e76ea491-1b3c-4251-9e8f-a8a5e8d50397
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,038
supabase-export-v2
c2e8f1e69a115e82
*fileobj* is not closed, when :class:`TarFile` is closed. *format* controls the archive format for writing. It must be one of the constants :const:`USTAR_FORMAT`, :const:`GNU_FORMAT` or :const:`PAX_FORMAT` that are defined at module level. When reading, format will be automatically detected, even if different format...
trusted_official_docs
CPython Docs
*fileobj* is not closed, when :class:`TarFile` is closed. *format* controls the archive format for writing. It must be one of the constants :const:`USTAR_FORMAT`, :const:`GNU_FORMAT` or :const:`PAX_FORMAT` that are defined at module level. When reading, format will be automatically detected, even if different format...
*fileobj* is not closed, when :class:`TarFile` is closed. *format* controls the archive format for writing. It must be one of the constants :const:`USTAR_FORMAT`, :const:`GNU_FORMAT` or :const:`PAX_FORMAT` that are defined at module level. When reading, format will be automatically detected, even if different format...
python, official-docs, cpython, P0
Local_Trusted_Corpus
e8692e15-9ff9-4ee3-a035-06a9e99e7380
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,034
supabase-export-v2
14ed0a68cd326595
be a :term:`path-like object`. It can be omitted if *fileobj* is given. In this case, the file object's :attr:`!name` attribute is used if it exists. *mode* is either ``'r'`` to read from an existing archive, ``'a'`` to append data to an existing file, ``'w'`` to create a new file overwriting an existing one, or ``'x...
trusted_official_docs
CPython Docs
be a :term:`path-like object`. It can be omitted if *fileobj* is given. In this case, the file object's :attr:`!name` attribute is used if it exists. *mode* is either ``'r'`` to read from an existing archive, ``'a'`` to append data to an existing file, ``'w'`` to create a new file overwriting an existing one, or ``'x...
be a :term:`path-like object`. It can be omitted if *fileobj* is given. In this case, the file object's :attr:`!name` attribute is used if it exists. *mode* is either ``'r'`` to read from an existing archive, ``'a'`` to append data to an existing file, ``'w'`` to create a new file overwriting an existing one, or ``'x...
python, official-docs, cpython, P0
Local_Trusted_Corpus
ea6d6c9b-77e5-4080-a0ae-ea20fc18c2f9
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,237
supabase-export-v2
fedc39e20efe818a
symlinks) would end up outside the destination. This raises :class:`~tarfile.OutsideDestinationError`. - Clear high mode bits (setuid, setgid, sticky) and group/other write bits (:const:`~stat.S_IWGRP` | :const:`~stat.S_IWOTH`). Return the modified ``TarInfo`` member.
trusted_official_docs
CPython Docs
symlinks) would end up outside the destination. This raises :class:`~tarfile.OutsideDestinationError`. - Clear high mode bits (setuid, setgid, sticky) and group/other write bits (:const:`~stat.S_IWGRP` | :const:`~stat.S_IWOTH`). Return the modified ``TarInfo`` member.
symlinks) would end up outside the destination. This raises :class:`~tarfile.OutsideDestinationError`. - Clear high mode bits (setuid, setgid, sticky) and group/other write bits (:const:`~stat.S_IWGRP` | :const:`~stat.S_IWOTH`). Return the modified ``TarInfo`` member.
python, official-docs, cpython, P0
Local_Trusted_Corpus
ec3cce17-4e48-4ebb-9be9-7946d31204b8
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,045
supabase-export-v2
3805bec19ed3eabb
the archive and how conversion errors are going to be handled. The default settings will work for most users. See section :ref:`tar-unicode` for in-depth information. The *pax_headers* argument is an optional dictionary of strings which will be added as a pax global header if *format* is :const:`PAX_FORMAT`.
trusted_official_docs
CPython Docs
the archive and how conversion errors are going to be handled. The default settings will work for most users. See section :ref:`tar-unicode` for in-depth information. The *pax_headers* argument is an optional dictionary of strings which will be added as a pax global header if *format* is :const:`PAX_FORMAT`.
the archive and how conversion errors are going to be handled. The default settings will work for most users. See section :ref:`tar-unicode` for in-depth information. The *pax_headers* argument is an optional dictionary of strings which will be added as a pax global header if *format* is :const:`PAX_FORMAT`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
f1f47c9f-1442-4641-8f5c-055f00346176
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,153
supabase-export-v2
a70087e2529bcd2d
:const:`REGTYPE`, :const:`AREGTYPE`, :const:`LNKTYPE`, :const:`SYMTYPE`, :const:`DIRTYPE`, :const:`FIFOTYPE`, :const:`CONTTYPE`, :const:`CHRTYPE`, :const:`BLKTYPE`, :const:`GNUTYPE_SPARSE`. To determine the type of a :class:`TarInfo` object more conveniently, use the ``is*()`` methods below. .. attribute:: TarInfo.link...
trusted_official_docs
CPython Docs
:const:`REGTYPE`, :const:`AREGTYPE`, :const:`LNKTYPE`, :const:`SYMTYPE`, :const:`DIRTYPE`, :const:`FIFOTYPE`, :const:`CONTTYPE`, :const:`CHRTYPE`, :const:`BLKTYPE`, :const:`GNUTYPE_SPARSE`. To determine the type of a :class:`TarInfo` object more conveniently, use the ``is*()`` methods below. .. attribute:: TarInfo.link...
:const:`REGTYPE`, :const:`AREGTYPE`, :const:`LNKTYPE`, :const:`SYMTYPE`, :const:`DIRTYPE`, :const:`FIFOTYPE`, :const:`CONTTYPE`, :const:`CHRTYPE`, :const:`BLKTYPE`, :const:`GNUTYPE_SPARSE`. To determine the type of a :class:`TarInfo` object more conveniently, use the ``is*()`` methods below. .. attribute:: TarInfo.link...
python, official-docs, cpython, P0
Local_Trusted_Corpus
fa6c02ec-eacb-4887-986b-f84deb885303
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,344
supabase-export-v2
9ef5c607829a40ff
autodetect the encoding of an archive. The pax format was designed to solve this problem. It stores non-ASCII metadata using the universal character encoding *UTF-8*. The details of character conversion in :mod:`!tarfile` are controlled by the *encoding* and *errors* keyword arguments of the :class:`TarFile` class.
trusted_official_docs
CPython Docs
autodetect the encoding of an archive. The pax format was designed to solve this problem. It stores non-ASCII metadata using the universal character encoding *UTF-8*. The details of character conversion in :mod:`!tarfile` are controlled by the *encoding* and *errors* keyword arguments of the :class:`TarFile` class.
autodetect the encoding of an archive. The pax format was designed to solve this problem. It stores non-ASCII metadata using the universal character encoding *UTF-8*. The details of character conversion in :mod:`!tarfile` are controlled by the *encoding* and *errors* keyword arguments of the :class:`TarFile` class.
python, official-docs, cpython, P0
Local_Trusted_Corpus
fd15cdf9-1195-4a3a-aec0-32bce75167f9
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,106
supabase-export-v2
555077513352562f
.. method:: TarFile.add(name, arcname=None, recursive=True, *, filter=None) Add the file *name* to the archive. *name* may be any type of file (directory, fifo, symbolic link, etc.). If given, *arcname* specifies an alternative name for the file in the archive. Directories are added recursively by default. This can ...
trusted_official_docs
CPython Docs
.. method:: TarFile.add(name, arcname=None, recursive=True, *, filter=None) Add the file *name* to the archive. *name* may be any type of file (directory, fifo, symbolic link, etc.). If given, *arcname* specifies an alternative name for the file in the archive. Directories are added recursively by default. This can ...
.. method:: TarFile.add(name, arcname=None, recursive=True, *, filter=None) Add the file *name* to the archive. *name* may be any type of file (directory, fifo, symbolic link, etc.). If given, *arcname* specifies an alternative name for the file in the archive. Directories are added recursively by default. This can ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
fe23eeee-6b1a-4023-886e-875a32a81d74
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,261
supabase-export-v2
f292459f442e7cf8
Also note that: * Tar files may contain multiple versions of the same file. Later ones are expected to overwrite any earlier ones. This feature is crucial to allow updating tape archives, but can be abused maliciously. * *tarfile* does not protect against issues with “live” data, e.g. an attacker tinkering with the d...
trusted_official_docs
CPython Docs
Also note that: * Tar files may contain multiple versions of the same file. Later ones are expected to overwrite any earlier ones. This feature is crucial to allow updating tape archives, but can be abused maliciously. * *tarfile* does not protect against issues with “live” data, e.g. an attacker tinkering with the d...
Also note that: * Tar files may contain multiple versions of the same file. Later ones are expected to overwrite any earlier ones. This feature is crucial to allow updating tape archives, but can be abused maliciously. * *tarfile* does not protect against issues with “live” data, e.g. an attacker tinkering with the d...
python, official-docs, cpython, P0
Local_Trusted_Corpus
fedde23c-fa79-4aac-b097-5563b7fbf6c3
CPython Docs
file://datasets/cpython/Doc/library/tarfile.rst
unknown
01fad262-38a9-468a-9368-93abc6076b7e
47,127
supabase-export-v2
3706a3aa986b5ef4
Several attributes can be set to ``None`` to indicate that a piece of metadata is unused or unknown. Different :class:`TarInfo` methods handle ``None`` differently: - The :meth:`~TarFile.extract` or :meth:`~TarFile.extractall` methods will ignore the corresponding metadata, leaving it set to a default. - :meth:`~TarFi...
trusted_official_docs
CPython Docs
Several attributes can be set to ``None`` to indicate that a piece of metadata is unused or unknown. Different :class:`TarInfo` methods handle ``None`` differently: - The :meth:`~TarFile.extract` or :meth:`~TarFile.extractall` methods will ignore the corresponding metadata, leaving it set to a default. - :meth:`~TarFi...
Several attributes can be set to ``None`` to indicate that a piece of metadata is unused or unknown. Different :class:`TarInfo` methods handle ``None`` differently: - The :meth:`~TarFile.extract` or :meth:`~TarFile.extractall` methods will ignore the corresponding metadata, leaving it set to a default. - :meth:`~TarFi...
python, official-docs, cpython, P0
Local_Trusted_Corpus
81413449-9397-4372-a82f-d418f24c1701
CPython Docs
file://datasets/cpython/Doc/library/numeric.rst
unknown
f2f09f71-6ec3-4110-b2c4-f531d2fe4ac6
47,349
supabase-export-v2
659b877131fbb00c
******************************** Numeric and Mathematical Modules ******************************** The modules described in this chapter provide numeric and math-related functions and data types. The :mod:`numbers` module defines an abstract hierarchy of numeric types. The :mod:`math` and :mod:`cmath` modules contain v...
trusted_official_docs
CPython Docs
******************************** Numeric and Mathematical Modules ******************************** The modules described in this chapter provide numeric and math-related functions and data types. The :mod:`numbers` module defines an abstract hierarchy of numeric types. The :mod:`math` and :mod:`cmath` modules contain v...
******************************** Numeric and Mathematical Modules ******************************** The modules described in this chapter provide numeric and math-related functions and data types. The :mod:`numbers` module defines an abstract hierarchy of numeric types. The :mod:`math` and :mod:`cmath` modules contain v...
python, official-docs, cpython, P0
Local_Trusted_Corpus
fafe177f-ee34-4f2d-8d64-67707c648d6e
CPython Docs
file://datasets/cpython/Doc/library/numeric.rst
unknown
f2f09f71-6ec3-4110-b2c4-f531d2fe4ac6
47,350
supabase-export-v2
b79093db4ca85b85
and :mod:`cmath` modules contain various mathematical functions for floating-point and complex numbers. The :mod:`decimal` module supports exact representations of decimal numbers, using arbitrary precision arithmetic. The following modules are documented in this chapter:
trusted_official_docs
CPython Docs
and :mod:`cmath` modules contain various mathematical functions for floating-point and complex numbers. The :mod:`decimal` module supports exact representations of decimal numbers, using arbitrary precision arithmetic. The following modules are documented in this chapter:
and :mod:`cmath` modules contain various mathematical functions for floating-point and complex numbers. The :mod:`decimal` module supports exact representations of decimal numbers, using arbitrary precision arithmetic. The following modules are documented in this chapter:
python, official-docs, cpython, P0
Local_Trusted_Corpus
01001e3b-91ae-4994-8faf-2e6fd588aeec
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,484
supabase-export-v2
683c1be08a61c7e6
your application to send both CAN and CAN FD frames; however, you must accept both CAN and CAN FD frames when reading from the socket. This constant is documented in the Linux documentation.
trusted_official_docs
CPython Docs
your application to send both CAN and CAN FD frames; however, you must accept both CAN and CAN FD frames when reading from the socket. This constant is documented in the Linux documentation.
your application to send both CAN and CAN FD frames; however, you must accept both CAN and CAN FD frames when reading from the socket. This constant is documented in the Linux documentation.
python, official-docs, cpython, P0
Local_Trusted_Corpus
019f0d54-339e-4095-9c8d-3fee5a0441f6
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,413
supabase-export-v2
1d55c59aaf7e25b3
.. availability:: Linux >= 2.2. - :const:`AF_QIPCRTR` is a Linux-only socket based interface for communicating with services running on co-processors in Qualcomm platforms. The address family is represented as a ``(node, port)`` tuple where the *node* and *port* are non-negative integers.
trusted_official_docs
CPython Docs
.. availability:: Linux >= 2.2. - :const:`AF_QIPCRTR` is a Linux-only socket based interface for communicating with services running on co-processors in Qualcomm platforms. The address family is represented as a ``(node, port)`` tuple where the *node* and *port* are non-negative integers.
.. availability:: Linux >= 2.2. - :const:`AF_QIPCRTR` is a Linux-only socket based interface for communicating with services running on co-processors in Qualcomm platforms. The address family is represented as a ``(node, port)`` tuple where the *node* and *port* are non-negative integers.
python, official-docs, cpython, P0
Local_Trusted_Corpus
02406936-b96c-4d84-8fdd-a16eea837586
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,824
supabase-export-v2
d00a87ba5cc134a4
On other platforms, the generic :func:`fcntl.fcntl` and :func:`fcntl.ioctl` functions may be used; they accept a socket object as their first argument. Currently only the following control codes are supported: ``SIO_RCVALL``, ``SIO_KEEPALIVE_VALS``, and ``SIO_LOOPBACK_FAST_PATH``.
trusted_official_docs
CPython Docs
On other platforms, the generic :func:`fcntl.fcntl` and :func:`fcntl.ioctl` functions may be used; they accept a socket object as their first argument. Currently only the following control codes are supported: ``SIO_RCVALL``, ``SIO_KEEPALIVE_VALS``, and ``SIO_LOOPBACK_FAST_PATH``.
On other platforms, the generic :func:`fcntl.fcntl` and :func:`fcntl.ioctl` functions may be used; they accept a socket object as their first argument. Currently only the following control codes are supported: ``SIO_RCVALL``, ``SIO_KEEPALIVE_VALS``, and ``SIO_LOOPBACK_FAST_PATH``.
python, official-docs, cpython, P0
Local_Trusted_Corpus
02812bf3-efe6-44a7-a57c-5b803d4f770c
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,385
supabase-export-v2
3c91e63f57fc9004
are 64-bit unsigned integer representing the ECU name, a 32-bit unsigned integer representing the Parameter Group Number (PGN), and an 8-bit integer representing the address. - A string or a tuple ``(id, unit)`` is used for the :const:`SYSPROTO_CONTROL` protocol of the :const:`PF_SYSTEM` family. The string is the name...
trusted_official_docs
CPython Docs
are 64-bit unsigned integer representing the ECU name, a 32-bit unsigned integer representing the Parameter Group Number (PGN), and an 8-bit integer representing the address. - A string or a tuple ``(id, unit)`` is used for the :const:`SYSPROTO_CONTROL` protocol of the :const:`PF_SYSTEM` family. The string is the name...
are 64-bit unsigned integer representing the ECU name, a 32-bit unsigned integer representing the Parameter Group Number (PGN), and an 8-bit integer representing the address. - A string or a tuple ``(id, unit)`` is used for the :const:`SYSPROTO_CONTROL` protocol of the :const:`PF_SYSTEM` family. The string is the name...
python, official-docs, cpython, P0
Local_Trusted_Corpus
03d0461a-8b1b-49fb-bc81-4185a9e84c68
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,632
supabase-export-v2
9cba868a958b782e
a numeric port number or ``None``. By passing ``None`` as the value of *host* and *port*, you can pass ``NULL`` to the underlying C API. The *family*, *type* and *proto* arguments can be optionally specified in order to provide options and limit the list of addresses returned. Pass their default values (:data:`AF_UNSP...
trusted_official_docs
CPython Docs
a numeric port number or ``None``. By passing ``None`` as the value of *host* and *port*, you can pass ``NULL`` to the underlying C API. The *family*, *type* and *proto* arguments can be optionally specified in order to provide options and limit the list of addresses returned. Pass their default values (:data:`AF_UNSP...
a numeric port number or ``None``. By passing ``None`` as the value of *host* and *port*, you can pass ``NULL`` to the underlying C API. The *family*, *type* and *proto* arguments can be optionally specified in order to provide options and limit the list of addresses returned. Pass their default values (:data:`AF_UNSP...
python, official-docs, cpython, P0
Local_Trusted_Corpus
04fdf8d6-5604-42dc-8b4a-08362af3962e
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,646
supabase-export-v2
412cf53a7eac1b97
following example fetches address information for a hypothetical TCP connection to ``example.org`` on port 80 (results may differ on your system if IPv6 isn't enabled):: >>> socket.getaddrinfo("example.org", 80, proto=socket.IPPROTO_TCP) [(socket.AF_INET6, socket.SOCK_STREAM, 6, '', ('2606:2800:220:1:248:1893:25c8:19...
trusted_official_docs
CPython Docs
following example fetches address information for a hypothetical TCP connection to ``example.org`` on port 80 (results may differ on your system if IPv6 isn't enabled):: >>> socket.getaddrinfo("example.org", 80, proto=socket.IPPROTO_TCP) [(socket.AF_INET6, socket.SOCK_STREAM, 6, '', ('2606:2800:220:1:248:1893:25c8:19...
following example fetches address information for a hypothetical TCP connection to ``example.org`` on port 80 (results may differ on your system if IPv6 isn't enabled):: >>> socket.getaddrinfo("example.org", 80, proto=socket.IPPROTO_TCP) [(socket.AF_INET6, socket.SOCK_STREAM, 6, '', ('2606:2800:220:1:248:1893:25c8:19...
python, official-docs, cpython, P0
Local_Trusted_Corpus
060099b3-6b04-4106-92ba-0eb62e117fe9
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,809
supabase-export-v2
23b90d118acae768
.. method:: socket.getpeername() Return the remote address to which the socket is connected. This is useful to find out the port number of a remote IPv4/v6 socket, for instance. The format of the address returned depends on the address family --- see :ref:`socket-addresses`. On some systems this function is not suppo...
trusted_official_docs
CPython Docs
.. method:: socket.getpeername() Return the remote address to which the socket is connected. This is useful to find out the port number of a remote IPv4/v6 socket, for instance. The format of the address returned depends on the address family --- see :ref:`socket-addresses`. On some systems this function is not suppo...
.. method:: socket.getpeername() Return the remote address to which the socket is connected. This is useful to find out the port number of a remote IPv4/v6 socket, for instance. The format of the address returned depends on the address family --- see :ref:`socket-addresses`. On some systems this function is not suppo...
python, official-docs, cpython, P0
Local_Trusted_Corpus
072ad1a4-049a-4962-96bd-6a5957c6d1a3
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,393
supabase-export-v2
9f4f8ee353c6a67f
- :const:`BTPROTO_HCI` accepts a format that depends on your OS. - On Linux it accepts an integer ``device_id`` or a tuple ``(device_id, [channel])`` where ``device_id`` specifies the number of the Bluetooth device, and ``channel`` is an optional integer specifying the HCI channel (:const:`HCI_CHANNEL_RAW` by defau...
trusted_official_docs
CPython Docs
- :const:`BTPROTO_HCI` accepts a format that depends on your OS. - On Linux it accepts an integer ``device_id`` or a tuple ``(device_id, [channel])`` where ``device_id`` specifies the number of the Bluetooth device, and ``channel`` is an optional integer specifying the HCI channel (:const:`HCI_CHANNEL_RAW` by defau...
- :const:`BTPROTO_HCI` accepts a format that depends on your OS. - On Linux it accepts an integer ``device_id`` or a tuple ``(device_id, [channel])`` where ``device_id`` specifies the number of the Bluetooth device, and ``channel`` is an optional integer specifying the HCI channel (:const:`HCI_CHANNEL_RAW` by defau...
python, official-docs, cpython, P0
Local_Trusted_Corpus
07eff66c-9751-4272-9e3a-40bd3b02e64f
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,711
supabase-export-v2
dc710a13c6266135
.. function:: inet_ntop(address_family, packed_ip) Convert a packed IP address (a :term:`bytes-like object` of some number of bytes) to its standard, family-specific string representation (for example, ``'7.10.0.5'`` or ``'5aef:2b::8'``). :func:`inet_ntop` is useful when a library or network protocol returns an obje...
trusted_official_docs
CPython Docs
.. function:: inet_ntop(address_family, packed_ip) Convert a packed IP address (a :term:`bytes-like object` of some number of bytes) to its standard, family-specific string representation (for example, ``'7.10.0.5'`` or ``'5aef:2b::8'``). :func:`inet_ntop` is useful when a library or network protocol returns an obje...
.. function:: inet_ntop(address_family, packed_ip) Convert a packed IP address (a :term:`bytes-like object` of some number of bytes) to its standard, family-specific string representation (for example, ``'7.10.0.5'`` or ``'5aef:2b::8'``). :func:`inet_ntop` is useful when a library or network protocol returns an obje...
python, official-docs, cpython, P0
Local_Trusted_Corpus
0825dae3-4ac2-47cb-8741-e5e38b9c0471
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,600
supabase-export-v2
a82f9d942f8231c3
to all possible addresses in turn until a connection succeeds. This makes it easy to write clients that are compatible to both IPv4 and IPv6. Passing the optional *timeout* parameter will set the timeout on the socket instance before attempting to connect. If no *timeout* is supplied, the global default timeout setti...
trusted_official_docs
CPython Docs
to all possible addresses in turn until a connection succeeds. This makes it easy to write clients that are compatible to both IPv4 and IPv6. Passing the optional *timeout* parameter will set the timeout on the socket instance before attempting to connect. If no *timeout* is supplied, the global default timeout setti...
to all possible addresses in turn until a connection succeeds. This makes it easy to write clients that are compatible to both IPv4 and IPv6. Passing the optional *timeout* parameter will set the timeout on the socket instance before attempting to connect. If no *timeout* is supplied, the global default timeout setti...
python, official-docs, cpython, P0
Local_Trusted_Corpus
0a25982e-38b9-446c-99b4-969d59916c59
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,434
supabase-export-v2
23bef52e0621b515
.. exception:: herror A subclass of :exc:`OSError`, this exception is raised for address-related errors, i.e. for functions that use *h_errno* in the POSIX C API, including :func:`gethostbyname_ex` and :func:`gethostbyaddr`. The accompanying value is a pair ``(h_errno, string)`` representing an error returned by a l...
trusted_official_docs
CPython Docs
.. exception:: herror A subclass of :exc:`OSError`, this exception is raised for address-related errors, i.e. for functions that use *h_errno* in the POSIX C API, including :func:`gethostbyname_ex` and :func:`gethostbyaddr`. The accompanying value is a pair ``(h_errno, string)`` representing an error returned by a l...
.. exception:: herror A subclass of :exc:`OSError`, this exception is raised for address-related errors, i.e. for functions that use *h_errno* in the POSIX C API, including :func:`gethostbyname_ex` and :func:`gethostbyaddr`. The accompanying value is a pair ``(h_errno, string)`` representing an error returned by a l...
python, official-docs, cpython, P0
Local_Trusted_Corpus
0afb5196-0285-418f-99f0-531d818c76d2
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,382
supabase-export-v2
96bb10a89ccf4474
If *addr_type* is :const:`TIPC_ADDR_NAMESEQ`, then *v1* is the server type, *v2* is the lower port number, and *v3* is the upper port number. If *addr_type* is :const:`TIPC_ADDR_ID`, then *v1* is the node, *v2* is the reference, and *v3* should be set to 0.
trusted_official_docs
CPython Docs
If *addr_type* is :const:`TIPC_ADDR_NAMESEQ`, then *v1* is the server type, *v2* is the lower port number, and *v3* is the upper port number. If *addr_type* is :const:`TIPC_ADDR_ID`, then *v1* is the node, *v2* is the reference, and *v3* should be set to 0.
If *addr_type* is :const:`TIPC_ADDR_NAMESEQ`, then *v1* is the server type, *v2* is the lower port number, and *v3* is the upper port number. If *addr_type* is :const:`TIPC_ADDR_ID`, then *v1* is the node, *v2* is the reference, and *v3* should be set to 0.
python, official-docs, cpython, P0
Local_Trusted_Corpus
0c9e6f18-c096-4701-8f4b-d52a6c9f4642
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,658
supabase-export-v2
90aa2440278c77b2
(often but not always a single address). :func:`gethostbyname_ex` does not support IPv6 name resolution, and :func:`getaddrinfo` should be used instead for IPv4/v6 dual stack support. .. audit-event:: socket.gethostbyname hostname socket.gethostbyname_ex
trusted_official_docs
CPython Docs
(often but not always a single address). :func:`gethostbyname_ex` does not support IPv6 name resolution, and :func:`getaddrinfo` should be used instead for IPv4/v6 dual stack support. .. audit-event:: socket.gethostbyname hostname socket.gethostbyname_ex
(often but not always a single address). :func:`gethostbyname_ex` does not support IPv6 name resolution, and :func:`getaddrinfo` should be used instead for IPv4/v6 dual stack support. .. audit-event:: socket.gethostbyname hostname socket.gethostbyname_ex
python, official-docs, cpython, P0
Local_Trusted_Corpus
0ccb85e9-3d7a-46f2-ac12-2087569cdc5c
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,638
supabase-export-v2
350de76db2fee852
*sockaddr* can be one of the following: * a ``(address, port)`` 2-tuple for :const:`AF_INET` * a ``(address, port, flowinfo, scope_id)`` 4-tuple for :const:`AF_INET6` if Python was compiled with ``--enable-ipv6`` (the default) * a 2-tuple containing raw data for :const:`AF_INET6` if Python was compiled with ``--dis...
trusted_official_docs
CPython Docs
*sockaddr* can be one of the following: * a ``(address, port)`` 2-tuple for :const:`AF_INET` * a ``(address, port, flowinfo, scope_id)`` 4-tuple for :const:`AF_INET6` if Python was compiled with ``--enable-ipv6`` (the default) * a 2-tuple containing raw data for :const:`AF_INET6` if Python was compiled with ``--dis...
*sockaddr* can be one of the following: * a ``(address, port)`` 2-tuple for :const:`AF_INET` * a ``(address, port, flowinfo, scope_id)`` 4-tuple for :const:`AF_INET6` if Python was compiled with ``--enable-ipv6`` (the default) * a 2-tuple containing raw data for :const:`AF_INET6` if Python was compiled with ``--dis...
python, official-docs, cpython, P0
Local_Trusted_Corpus
0e27d2cd-b5a6-4cf9-bf97-3e8c5ddc5c8f
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,843
supabase-export-v2
7319fed40955f2a2
:manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults to zero. The format of *address* depends on the address family --- see :ref:`socket-addresses`. .. versionchanged:: 3.5 If the system call is interrupted and the signal handler does not raise an exception, the method now retries the syst...
trusted_official_docs
CPython Docs
:manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults to zero. The format of *address* depends on the address family --- see :ref:`socket-addresses`. .. versionchanged:: 3.5 If the system call is interrupted and the signal handler does not raise an exception, the method now retries the syst...
:manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults to zero. The format of *address* depends on the address family --- see :ref:`socket-addresses`. .. versionchanged:: 3.5 If the system call is interrupted and the signal handler does not raise an exception, the method now retries the syst...
python, official-docs, cpython, P0
Local_Trusted_Corpus
0f433d79-76b1-4683-970a-8f2499e369a5
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,608
supabase-export-v2
bdfc77e7e56be520
the queue size passed to :meth:`socket.listen`; if not specified , a default reasonable value is chosen. *reuse_port* dictates whether to set the :data:`SO_REUSEPORT` socket option. If *dualstack_ipv6* is true, *family* is :data:`AF_INET6` and the platform supports it the socket will be able to accept both IPv4 and IP...
trusted_official_docs
CPython Docs
the queue size passed to :meth:`socket.listen`; if not specified , a default reasonable value is chosen. *reuse_port* dictates whether to set the :data:`SO_REUSEPORT` socket option. If *dualstack_ipv6* is true, *family* is :data:`AF_INET6` and the platform supports it the socket will be able to accept both IPv4 and IP...
the queue size passed to :meth:`socket.listen`; if not specified , a default reasonable value is chosen. *reuse_port* dictates whether to set the :data:`SO_REUSEPORT` socket option. If *dualstack_ipv6* is true, *family* is :data:`AF_INET6` and the platform supports it the socket will be able to accept both IPv4 and IP...
python, official-docs, cpython, P0
Local_Trusted_Corpus
0f906d7c-e5be-4929-ad40-0baac7f6b536
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,697
supabase-export-v2
08504314ad5b6aa3
.. function:: inet_aton(ip_string) Convert an IPv4 address from dotted-quad string format (for example, '123.45.67.89') to 32-bit packed binary format, as a bytes object four characters in length. This is useful when conversing with a program that uses the standard C library and needs objects of type :c:struct:`in_a...
trusted_official_docs
CPython Docs
.. function:: inet_aton(ip_string) Convert an IPv4 address from dotted-quad string format (for example, '123.45.67.89') to 32-bit packed binary format, as a bytes object four characters in length. This is useful when conversing with a program that uses the standard C library and needs objects of type :c:struct:`in_a...
.. function:: inet_aton(ip_string) Convert an IPv4 address from dotted-quad string format (for example, '123.45.67.89') to 32-bit packed binary format, as a bytes object four characters in length. This is useful when conversing with a program that uses the standard C library and needs objects of type :c:struct:`in_a...
python, official-docs, cpython, P0
Local_Trusted_Corpus
0fec662b-a3f7-4036-b666-8cb13fa055fe
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,863
supabase-export-v2
dd9e039765d305c4
:manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults to zero. The format of *address* depends on the address family --- see :ref:`socket-addresses`. .. method:: socket.recv_into(buffer[, nbytes[, flags]])
trusted_official_docs
CPython Docs
:manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults to zero. The format of *address* depends on the address family --- see :ref:`socket-addresses`. .. method:: socket.recv_into(buffer[, nbytes[, flags]])
:manpage:`recv(2)` for the meaning of the optional argument *flags*; it defaults to zero. The format of *address* depends on the address family --- see :ref:`socket-addresses`. .. method:: socket.recv_into(buffer[, nbytes[, flags]])
python, official-docs, cpython, P0
Local_Trusted_Corpus
11d4cb9e-0f56-449e-9138-fa0132b71e0b
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,657
supabase-export-v2
0f9bd9d08cd62819
.. function:: gethostbyname_ex(hostname) Translate a host name to IPv4 address format, extended interface. Return a 3-tuple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the host's primary host name, *aliaslist* is a (possibly empty) list of alternative host names for the same address, and *ipaddrlist* i...
trusted_official_docs
CPython Docs
.. function:: gethostbyname_ex(hostname) Translate a host name to IPv4 address format, extended interface. Return a 3-tuple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the host's primary host name, *aliaslist* is a (possibly empty) list of alternative host names for the same address, and *ipaddrlist* i...
.. function:: gethostbyname_ex(hostname) Translate a host name to IPv4 address format, extended interface. Return a 3-tuple ``(hostname, aliaslist, ipaddrlist)`` where *hostname* is the host's primary host name, *aliaslist* is a (possibly empty) list of alternative host names for the same address, and *ipaddrlist* i...
python, official-docs, cpython, P0
Local_Trusted_Corpus
1364deff-dbd3-42a7-b4bc-35f650111ba0
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,671
supabase-export-v2
665e309a48f3f8f0
contain a fully qualified domain name or numeric address representation in *host*. Similarly, *port* can contain a string port name or a numeric port number. For IPv6 addresses, ``%scope_id`` is appended to the host part if *sockaddr* contains meaningful *scope_id*. Usually this happens for multicast addresses.
trusted_official_docs
CPython Docs
contain a fully qualified domain name or numeric address representation in *host*. Similarly, *port* can contain a string port name or a numeric port number. For IPv6 addresses, ``%scope_id`` is appended to the host part if *sockaddr* contains meaningful *scope_id*. Usually this happens for multicast addresses.
contain a fully qualified domain name or numeric address representation in *host*. Similarly, *port* can contain a string port name or a numeric port number. For IPv6 addresses, ``%scope_id`` is appended to the host part if *sockaddr* contains meaningful *scope_id*. Usually this happens for multicast addresses.
python, official-docs, cpython, P0
Local_Trusted_Corpus
14b88f1c-a905-45a1-b97c-e586f8da8424
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,593
supabase-export-v2
fd8eb98bf0bf287a
.. function:: socketpair([family[, type[, proto]]]) Build a pair of connected socket objects using the given address family, socket type, and protocol number. Address family, socket type, and protocol number are as for the :func:`~socket.socket` function. The default family is :const:`AF_UNIX` if defined on the plat...
trusted_official_docs
CPython Docs
.. function:: socketpair([family[, type[, proto]]]) Build a pair of connected socket objects using the given address family, socket type, and protocol number. Address family, socket type, and protocol number are as for the :func:`~socket.socket` function. The default family is :const:`AF_UNIX` if defined on the plat...
.. function:: socketpair([family[, type[, proto]]]) Build a pair of connected socket objects using the given address family, socket type, and protocol number. Address family, socket type, and protocol number are as for the :func:`~socket.socket` function. The default family is :const:`AF_UNIX` if defined on the plat...
python, official-docs, cpython, P0
Local_Trusted_Corpus
156dca2e-84ad-4a43-9fa3-4d03bf89830a
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,532
supabase-export-v2
958729d20e5ce9d8
string constants containing Bluetooth addresses with special meanings. For example, :const:`BDADDR_ANY` can be used to indicate any address when specifying the binding socket with :const:`BTPROTO_RFCOMM`. .. data:: BDADDR_BREDR BDADDR_LE_PUBLIC BDADDR_LE_RANDOM
trusted_official_docs
CPython Docs
string constants containing Bluetooth addresses with special meanings. For example, :const:`BDADDR_ANY` can be used to indicate any address when specifying the binding socket with :const:`BTPROTO_RFCOMM`. .. data:: BDADDR_BREDR BDADDR_LE_PUBLIC BDADDR_LE_RANDOM
string constants containing Bluetooth addresses with special meanings. For example, :const:`BDADDR_ANY` can be used to indicate any address when specifying the binding socket with :const:`BTPROTO_RFCOMM`. .. data:: BDADDR_BREDR BDADDR_LE_PUBLIC BDADDR_LE_RANDOM
python, official-docs, cpython, P0
Local_Trusted_Corpus
16bd51df-e036-4f8c-98ef-94f1ebeceb72
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,772
supabase-export-v2
9e54e94972e1cd3c
.. method:: socket.accept() Accept a connection. The socket must be bound to an address and listening for connections. The return value is a pair ``(conn, address)`` where *conn* is a *new* socket object usable to send and receive data on the connection, and *address* is the address bound to the socket on the other ...
trusted_official_docs
CPython Docs
.. method:: socket.accept() Accept a connection. The socket must be bound to an address and listening for connections. The return value is a pair ``(conn, address)`` where *conn* is a *new* socket object usable to send and receive data on the connection, and *address* is the address bound to the socket on the other ...
.. method:: socket.accept() Accept a connection. The socket must be bound to an address and listening for connections. The return value is a pair ``(conn, address)`` where *conn* is a *new* socket object usable to send and receive data on the connection, and *address* is the address bound to the socket on the other ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
18155f77-7d56-4d16-bcea-94d596be039b
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,835
supabase-export-v2
a2a70f56089b0800
in blocking mode; it can have a timeout, but the file object's internal buffer may end up in an inconsistent state if a timeout occurs. Closing the file object returned by :meth:`makefile` won't close the original socket unless all other file objects have been closed and :meth:`socket.close` has been called on the so...
trusted_official_docs
CPython Docs
in blocking mode; it can have a timeout, but the file object's internal buffer may end up in an inconsistent state if a timeout occurs. Closing the file object returned by :meth:`makefile` won't close the original socket unless all other file objects have been closed and :meth:`socket.close` has been called on the so...
in blocking mode; it can have a timeout, but the file object's internal buffer may end up in an inconsistent state if a timeout occurs. Closing the file object returned by :meth:`makefile` won't close the original socket unless all other file objects have been closed and :meth:`socket.close` has been called on the so...
python, official-docs, cpython, P0
Local_Trusted_Corpus
18af9500-0212-4de7-8ebc-e4b326006de1
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,956
supabase-export-v2
106d0c9c546cfbfe
# disabled promiscuous mode s.ioctl(socket.SIO_RCVALL, socket.RCVALL_OFF) The next example shows how to use the socket interface to communicate to a CAN network using the raw socket protocol. To use CAN with the broadcast manager protocol instead, open a socket with::
trusted_official_docs
CPython Docs
# disabled promiscuous mode s.ioctl(socket.SIO_RCVALL, socket.RCVALL_OFF) The next example shows how to use the socket interface to communicate to a CAN network using the raw socket protocol. To use CAN with the broadcast manager protocol instead, open a socket with::
# disabled promiscuous mode s.ioctl(socket.SIO_RCVALL, socket.RCVALL_OFF) The next example shows how to use the socket interface to communicate to a CAN network using the raw socket protocol. To use CAN with the broadcast manager protocol instead, open a socket with::
python, official-docs, cpython, P0
Local_Trusted_Corpus
18c3903e-7573-4fc2-be5e-209561ce96e6
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,848
supabase-export-v2
83efd84d8896b237
system documentation for details. If the receiving socket is unconnected, *address* is the address of the sending socket, if available; otherwise, its value is unspecified. On some systems, :meth:`sendmsg` and :meth:`recvmsg` can be used to pass file descriptors between processes over an :const:`AF_UNIX` socket. When...
trusted_official_docs
CPython Docs
system documentation for details. If the receiving socket is unconnected, *address* is the address of the sending socket, if available; otherwise, its value is unspecified. On some systems, :meth:`sendmsg` and :meth:`recvmsg` can be used to pass file descriptors between processes over an :const:`AF_UNIX` socket. When...
system documentation for details. If the receiving socket is unconnected, *address* is the address of the sending socket, if available; otherwise, its value is unspecified. On some systems, :meth:`sendmsg` and :meth:`recvmsg` can be used to pass file descriptors between processes over an :const:`AF_UNIX` socket. When...
python, official-docs, cpython, P0
Local_Trusted_Corpus
19e58a55-f626-48bb-a5c2-e0bb55c77e10
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,856
supabase-export-v2
406dc790b648e139
.. method:: socket.recvmsg_into(buffers[, ancbufsize[, flags]]) Receive normal data and ancillary data from the socket, behaving as :meth:`recvmsg` would, but scatter the non-ancillary data into a series of buffers instead of returning a new bytes object. The *buffers* argument must be an iterable of objects that ex...
trusted_official_docs
CPython Docs
.. method:: socket.recvmsg_into(buffers[, ancbufsize[, flags]]) Receive normal data and ancillary data from the socket, behaving as :meth:`recvmsg` would, but scatter the non-ancillary data into a series of buffers instead of returning a new bytes object. The *buffers* argument must be an iterable of objects that ex...
.. method:: socket.recvmsg_into(buffers[, ancbufsize[, flags]]) Receive normal data and ancillary data from the socket, behaving as :meth:`recvmsg` would, but scatter the non-ancillary data into a series of buffers instead of returning a new bytes object. The *buffers* argument must be an iterable of objects that ex...
python, official-docs, cpython, P0
Local_Trusted_Corpus
1b3e43fa-bb55-4ee6-a249-6b93b8aef742
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,699
supabase-export-v2
87aa4b2e9a9c817b
:func:`inet_aton` also accepts strings with less than three dots; see the Unix manual page :manpage:`inet(3)` for details. If the IPv4 address string passed to this function is invalid, :exc:`OSError` will be raised. Note that exactly what is valid depends on the underlying C implementation of :c:func:`inet_aton`.
trusted_official_docs
CPython Docs
:func:`inet_aton` also accepts strings with less than three dots; see the Unix manual page :manpage:`inet(3)` for details. If the IPv4 address string passed to this function is invalid, :exc:`OSError` will be raised. Note that exactly what is valid depends on the underlying C implementation of :c:func:`inet_aton`.
:func:`inet_aton` also accepts strings with less than three dots; see the Unix manual page :manpage:`inet(3)` for details. If the IPv4 address string passed to this function is invalid, :exc:`OSError` will be raised. Note that exactly what is valid depends on the underlying C implementation of :c:func:`inet_aton`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
1bc795a1-ce0c-4a2a-ab51-03d06faab711
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,507
supabase-export-v2
70ef63ba33e25f72
:data:`!ETH_P_ALL` can be used in the :class:`~socket.socket` constructor as *proto* for the :const:`AF_PACKET` family in order to capture every packet, regardless of protocol. For more information, see the :manpage:`packet(7)` manpage.
trusted_official_docs
CPython Docs
:data:`!ETH_P_ALL` can be used in the :class:`~socket.socket` constructor as *proto* for the :const:`AF_PACKET` family in order to capture every packet, regardless of protocol. For more information, see the :manpage:`packet(7)` manpage.
:data:`!ETH_P_ALL` can be used in the :class:`~socket.socket` constructor as *proto* for the :const:`AF_PACKET` family in order to capture every packet, regardless of protocol. For more information, see the :manpage:`packet(7)` manpage.
python, official-docs, cpython, P0
Local_Trusted_Corpus
1cb9e43f-3405-4115-839b-ce048d3e0b20
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,847
supabase-export-v2
6bb961c7a2d7f80b
do not fit into the buffer might be truncated or discarded. The *flags* argument defaults to 0 and has the same meaning as for :meth:`recv`. The return value is a 4-tuple: ``(data, ancdata, msg_flags, address)``. The *data* item is a :class:`bytes` object holding the non-ancillary data received. The *ancdata* item is...
trusted_official_docs
CPython Docs
do not fit into the buffer might be truncated or discarded. The *flags* argument defaults to 0 and has the same meaning as for :meth:`recv`. The return value is a 4-tuple: ``(data, ancdata, msg_flags, address)``. The *data* item is a :class:`bytes` object holding the non-ancillary data received. The *ancdata* item is...
do not fit into the buffer might be truncated or discarded. The *flags* argument defaults to 0 and has the same meaning as for :meth:`recv`. The return value is a 4-tuple: ``(data, ancdata, msg_flags, address)``. The *data* item is a :class:`bytes` object holding the non-ancillary data received. The *ancdata* item is...
python, official-docs, cpython, P0
Local_Trusted_Corpus
1ccb5bce-615c-40c7-95c8-fd87358cd62d
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,400
supabase-export-v2
aab142435f7e13d1
based interface to Kernel cryptography. An algorithm socket is configured with a tuple of two to four elements ``(type, name [, feat [, mask]])``, where: - *type* is the algorithm type as string, e.g. ``aead``, ``hash``, ``skcipher`` or ``rng``.
trusted_official_docs
CPython Docs
based interface to Kernel cryptography. An algorithm socket is configured with a tuple of two to four elements ``(type, name [, feat [, mask]])``, where: - *type* is the algorithm type as string, e.g. ``aead``, ``hash``, ``skcipher`` or ``rng``.
based interface to Kernel cryptography. An algorithm socket is configured with a tuple of two to four elements ``(type, name [, feat [, mask]])``, where: - *type* is the algorithm type as string, e.g. ``aead``, ``hash``, ``skcipher`` or ``rng``.
python, official-docs, cpython, P0
Local_Trusted_Corpus
1d6140fa-3015-4a3a-bb61-362410c10182
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,878
supabase-export-v2
c494f618f18f8fd1
cmsg_data)``, where *cmsg_level* and *cmsg_type* are integers specifying the protocol level and protocol-specific type respectively, and *cmsg_data* is a bytes-like object holding the associated data. Note that some systems (in particular, systems without :func:`CMSG_SPACE`) might support sending only one control mes...
trusted_official_docs
CPython Docs
cmsg_data)``, where *cmsg_level* and *cmsg_type* are integers specifying the protocol level and protocol-specific type respectively, and *cmsg_data* is a bytes-like object holding the associated data. Note that some systems (in particular, systems without :func:`CMSG_SPACE`) might support sending only one control mes...
cmsg_data)``, where *cmsg_level* and *cmsg_type* are integers specifying the protocol level and protocol-specific type respectively, and *cmsg_data* is a bytes-like object holding the associated data. Note that some systems (in particular, systems without :func:`CMSG_SPACE`) might support sending only one control mes...
python, official-docs, cpython, P0
Local_Trusted_Corpus
1f8aa624-4f8b-4607-a61a-4fb83c0cea6b
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,812
supabase-export-v2
7a43b1a0f1236801
find out the port number of an IPv4/v6 socket, for instance. The format of the address returned depends on the address family --- see :ref:`socket-addresses`. .. method:: socket.getsockopt(level, optname[, buflen])
trusted_official_docs
CPython Docs
find out the port number of an IPv4/v6 socket, for instance. The format of the address returned depends on the address family --- see :ref:`socket-addresses`. .. method:: socket.getsockopt(level, optname[, buflen])
find out the port number of an IPv4/v6 socket, for instance. The format of the address returned depends on the address family --- see :ref:`socket-addresses`. .. method:: socket.getsockopt(level, optname[, buflen])
python, official-docs, cpython, P0
Local_Trusted_Corpus
22630a11-35ce-4f96-aced-763e45c49432
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,704
supabase-export-v2
9d9a7b1b8ac05bca
exactly 4 bytes in length, :exc:`OSError` will be raised. :func:`inet_ntoa` does not support IPv6, and :func:`inet_ntop` should be used instead for IPv4/v6 dual stack support. .. versionchanged:: 3.5 Writable :term:`bytes-like object` is now accepted.
trusted_official_docs
CPython Docs
exactly 4 bytes in length, :exc:`OSError` will be raised. :func:`inet_ntoa` does not support IPv6, and :func:`inet_ntop` should be used instead for IPv4/v6 dual stack support. .. versionchanged:: 3.5 Writable :term:`bytes-like object` is now accepted.
exactly 4 bytes in length, :exc:`OSError` will be raised. :func:`inet_ntoa` does not support IPv6, and :func:`inet_ntop` should be used instead for IPv4/v6 dual stack support. .. versionchanged:: 3.5 Writable :term:`bytes-like object` is now accepted.
python, official-docs, cpython, P0
Local_Trusted_Corpus
2583a85a-2f41-4aac-b463-4f86908f6925
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,469
supabase-export-v2
e768294e82b309f3
this constant can be used in the same way that ``SO_BINDTODEVICE`` is used, but with the index of a network interface instead of its name. .. versionchanged:: 3.14 Added missing ``IP_FREEBIND``, ``IP_RECVERR``, ``IPV6_RECVERR``, ``IP_RECVTTL``, and ``IP_RECVORIGDSTADDR`` on Linux.
trusted_official_docs
CPython Docs
this constant can be used in the same way that ``SO_BINDTODEVICE`` is used, but with the index of a network interface instead of its name. .. versionchanged:: 3.14 Added missing ``IP_FREEBIND``, ``IP_RECVERR``, ``IPV6_RECVERR``, ``IP_RECVTTL``, and ``IP_RECVORIGDSTADDR`` on Linux.
this constant can be used in the same way that ``SO_BINDTODEVICE`` is used, but with the index of a network interface instead of its name. .. versionchanged:: 3.14 Added missing ``IP_FREEBIND``, ``IP_RECVERR``, ``IPV6_RECVERR``, ``IP_RECVTTL``, and ``IP_RECVORIGDSTADDR`` on Linux.
python, official-docs, cpython, P0
Local_Trusted_Corpus
267ccc71-b114-4a40-88af-1fc74e9f0761
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,417
supabase-export-v2
974b10424722f7ab
and ``self.setsockopt(IPPROTO_UDPLITE, UDPLITE_RECV_CSCOV, length)`` will filter out packets which cover too little of their data. In both cases ``length`` should be in ``range(8, 2**16, 8)``. Such a socket should be constructed with ``socket(AF_INET, SOCK_DGRAM, IPPROTO_UDPLITE)`` for IPv4 or ``socket(AF_INET6, SOCK...
trusted_official_docs
CPython Docs
and ``self.setsockopt(IPPROTO_UDPLITE, UDPLITE_RECV_CSCOV, length)`` will filter out packets which cover too little of their data. In both cases ``length`` should be in ``range(8, 2**16, 8)``. Such a socket should be constructed with ``socket(AF_INET, SOCK_DGRAM, IPPROTO_UDPLITE)`` for IPv4 or ``socket(AF_INET6, SOCK...
and ``self.setsockopt(IPPROTO_UDPLITE, UDPLITE_RECV_CSCOV, length)`` will filter out packets which cover too little of their data. In both cases ``length`` should be in ``range(8, 2**16, 8)``. Such a socket should be constructed with ``socket(AF_INET, SOCK_DGRAM, IPPROTO_UDPLITE)`` for IPv4 or ``socket(AF_INET6, SOCK...
python, official-docs, cpython, P0
Local_Trusted_Corpus
288457e3-328d-438c-8df1-3e3857aa1087
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,723
supabase-export-v2
2a5104dacbf8c5ae
multiple items is the sum of the :func:`CMSG_SPACE` values for their associated data lengths. Raises :exc:`OverflowError` if *length* is outside the permissible range of values. Note that some systems might support ancillary data without providing this function. Also note that setting the buffer size using the result...
trusted_official_docs
CPython Docs
multiple items is the sum of the :func:`CMSG_SPACE` values for their associated data lengths. Raises :exc:`OverflowError` if *length* is outside the permissible range of values. Note that some systems might support ancillary data without providing this function. Also note that setting the buffer size using the result...
multiple items is the sum of the :func:`CMSG_SPACE` values for their associated data lengths. Raises :exc:`OverflowError` if *length* is outside the permissible range of values. Note that some systems might support ancillary data without providing this function. Also note that setting the buffer size using the result...
python, official-docs, cpython, P0
Local_Trusted_Corpus
28aaad87-8c46-4bb5-b50e-d7d16ad8785d
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,641
supabase-export-v2
3916c1a817d9d71f
for example, retrieve *canonname*), consider limiting the results by *type* (e.g. :data:`SOCK_STREAM` or :data:`SOCK_DGRAM`) and/or *proto* (e.g. :data:`IPPROTO_TCP` or :data:`IPPROTO_UDP`) that your application can handle. The behavior with default values of *family*, *type*, *proto* and *flags* is system-specific.
trusted_official_docs
CPython Docs
for example, retrieve *canonname*), consider limiting the results by *type* (e.g. :data:`SOCK_STREAM` or :data:`SOCK_DGRAM`) and/or *proto* (e.g. :data:`IPPROTO_TCP` or :data:`IPPROTO_UDP`) that your application can handle. The behavior with default values of *family*, *type*, *proto* and *flags* is system-specific.
for example, retrieve *canonname*), consider limiting the results by *type* (e.g. :data:`SOCK_STREAM` or :data:`SOCK_DGRAM`) and/or *proto* (e.g. :data:`IPPROTO_TCP` or :data:`IPPROTO_UDP`) that your application can handle. The behavior with default values of *family*, *type*, *proto* and *flags* is system-specific.
python, official-docs, cpython, P0
Local_Trusted_Corpus
2adf47e8-5d02-43c3-8ad8-7a2c46366bd6
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,846
supabase-export-v2
0071d436dbe9b268
.. method:: socket.recvmsg(bufsize[, ancbufsize[, flags]]) Receive normal data (up to *bufsize* bytes) and ancillary data from the socket. The *ancbufsize* argument sets the size in bytes of the internal buffer used to receive the ancillary data; it defaults to 0, meaning that no ancillary data will be received. App...
trusted_official_docs
CPython Docs
.. method:: socket.recvmsg(bufsize[, ancbufsize[, flags]]) Receive normal data (up to *bufsize* bytes) and ancillary data from the socket. The *ancbufsize* argument sets the size in bytes of the internal buffer used to receive the ancillary data; it defaults to 0, meaning that no ancillary data will be received. App...
.. method:: socket.recvmsg(bufsize[, ancbufsize[, flags]]) Receive normal data (up to *bufsize* bytes) and ancillary data from the socket. The *ancbufsize* argument sets the size in bytes of the internal buffer used to receive the ancillary data; it defaults to 0, meaning that no ancillary data will be received. App...
python, official-docs, cpython, P0
Local_Trusted_Corpus
2c5d6f05-e04b-4097-86b5-d33dcbb81e2e
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,406
supabase-export-v2
ef5b35f7711c0a0b
.. versionadded:: 3.6 - :const:`AF_VSOCK` allows communication between virtual machines and their hosts. The sockets are represented as a ``(CID, port)`` tuple where the context ID or CID and port are integers.
trusted_official_docs
CPython Docs
.. versionadded:: 3.6 - :const:`AF_VSOCK` allows communication between virtual machines and their hosts. The sockets are represented as a ``(CID, port)`` tuple where the context ID or CID and port are integers.
.. versionadded:: 3.6 - :const:`AF_VSOCK` allows communication between virtual machines and their hosts. The sockets are represented as a ``(CID, port)`` tuple where the context ID or CID and port are integers.
python, official-docs, cpython, P0
Local_Trusted_Corpus
2cd68c5d-4d12-4ebd-84be-d54d352e2126
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,937
supabase-export-v2
676d134f59880d2c
:func:`~socket.socket`, :meth:`~socket.connect`. Also note that the server does not :meth:`~socket.sendall`/:meth:`~socket.recv` on the socket it is listening on but on the new socket returned by :meth:`~socket.accept`. The first two examples support IPv4 only. ::
trusted_official_docs
CPython Docs
:func:`~socket.socket`, :meth:`~socket.connect`. Also note that the server does not :meth:`~socket.sendall`/:meth:`~socket.recv` on the socket it is listening on but on the new socket returned by :meth:`~socket.accept`. The first two examples support IPv4 only. ::
:func:`~socket.socket`, :meth:`~socket.connect`. Also note that the server does not :meth:`~socket.sendall`/:meth:`~socket.recv` on the socket it is listening on but on the new socket returned by :meth:`~socket.accept`. The first two examples support IPv4 only. ::
python, official-docs, cpython, P0
Local_Trusted_Corpus
2d5340bd-66ca-46c0-ad04-3c5e7ede58b1
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,859
supabase-export-v2
afb06ce41d5be1d4
Example:: >>> import socket >>> s1, s2 = socket.socketpair() >>> b1 = bytearray(b'----') >>> b2 = bytearray(b'0123456789') >>> b3 = bytearray(b'--------------') >>> s1.send(b'Mary had a little lamb') 22 >>> s2.recvmsg_into([b1, memoryview(b2)[2:9], b3]) (22, [], 0, None) >>> [b1, b2, b3] [bytearray(b'Mary'), ...
trusted_official_docs
CPython Docs
Example:: >>> import socket >>> s1, s2 = socket.socketpair() >>> b1 = bytearray(b'----') >>> b2 = bytearray(b'0123456789') >>> b3 = bytearray(b'--------------') >>> s1.send(b'Mary had a little lamb') 22 >>> s2.recvmsg_into([b1, memoryview(b2)[2:9], b3]) (22, [], 0, None) >>> [b1, b2, b3] [bytearray(b'Mary'), ...
Example:: >>> import socket >>> s1, s2 = socket.socketpair() >>> b1 = bytearray(b'----') >>> b2 = bytearray(b'0123456789') >>> b3 = bytearray(b'--------------') >>> s1.send(b'Mary had a little lamb') 22 >>> s2.recvmsg_into([b1, memoryview(b2)[2:9], b3]) (22, [], 0, None) >>> [b1, b2, b3] [bytearray(b'Mary'), ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
2e41094f-468d-4300-952f-82491910596c
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,794
supabase-export-v2
0d1a1718a6567e14
The error indicator is ``0`` if the operation succeeded, otherwise the value of the :c:data:`errno` variable. This is useful to support, for example, asynchronous connects. .. audit-event:: socket.connect self,address socket.socket.connect_ex
trusted_official_docs
CPython Docs
The error indicator is ``0`` if the operation succeeded, otherwise the value of the :c:data:`errno` variable. This is useful to support, for example, asynchronous connects. .. audit-event:: socket.connect self,address socket.socket.connect_ex
The error indicator is ``0`` if the operation succeeded, otherwise the value of the :c:data:`errno` variable. This is useful to support, for example, asynchronous connects. .. audit-event:: socket.connect self,address socket.socket.connect_ex
python, official-docs, cpython, P0
Local_Trusted_Corpus
2e92693d-346c-4cc5-9c22-7fbbeb81214a
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,640
supabase-export-v2
cc23b74b03dc7c21
.. note:: If you intend to use results from :func:`!getaddrinfo` to create a socket (rather than, for example, retrieve *canonname*), consider limiting the results by *type* (e.g. :data:`SOCK_STREAM` or :data:`SOCK_DGRAM`) and/or *proto* (e.g. :data:`IPPROTO_TCP` or :data:`IPPROTO_UDP`) that your application can ha...
trusted_official_docs
CPython Docs
.. note:: If you intend to use results from :func:`!getaddrinfo` to create a socket (rather than, for example, retrieve *canonname*), consider limiting the results by *type* (e.g. :data:`SOCK_STREAM` or :data:`SOCK_DGRAM`) and/or *proto* (e.g. :data:`IPPROTO_TCP` or :data:`IPPROTO_UDP`) that your application can ha...
.. note:: If you intend to use results from :func:`!getaddrinfo` to create a socket (rather than, for example, retrieve *canonname*), consider limiting the results by *type* (e.g. :data:`SOCK_STREAM` or :data:`SOCK_DGRAM`) and/or *proto* (e.g. :data:`IPPROTO_TCP` or :data:`IPPROTO_UDP`) that your application can ha...
python, official-docs, cpython, P0
Local_Trusted_Corpus
2f336f25-5f66-4617-91a6-1ab9b045d7c2
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,965
supabase-export-v2
64fc75752e33f831
def dissect_can_frame(frame): can_id, can_dlc, data = struct.unpack(can_frame_fmt, frame) return (can_id, can_dlc, data[:can_dlc]) # create a raw socket and bind it to the 'vcan0' interface s = socket.socket(socket.AF_CAN, socket.SOCK_RAW, socket.CAN_RAW) s.bind(('vcan0',))
trusted_official_docs
CPython Docs
def dissect_can_frame(frame): can_id, can_dlc, data = struct.unpack(can_frame_fmt, frame) return (can_id, can_dlc, data[:can_dlc]) # create a raw socket and bind it to the 'vcan0' interface s = socket.socket(socket.AF_CAN, socket.SOCK_RAW, socket.CAN_RAW) s.bind(('vcan0',))
def dissect_can_frame(frame): can_id, can_dlc, data = struct.unpack(can_frame_fmt, frame) return (can_id, can_dlc, data[:can_dlc]) # create a raw socket and bind it to the 'vcan0' interface s = socket.socket(socket.AF_CAN, socket.SOCK_RAW, socket.CAN_RAW) s.bind(('vcan0',))
python, official-docs, cpython, P0
Local_Trusted_Corpus
2fba3883-e35f-4217-b79f-1c459b322f41
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,706
supabase-export-v2
769bad38faab059e
.. function:: inet_pton(address_family, ip_string) Convert an IP address from its family-specific string format to a packed, binary format. :func:`inet_pton` is useful when a library or network protocol calls for an object of type :c:struct:`in_addr` (similar to :func:`inet_aton`) or :c:struct:`in6_addr`.
trusted_official_docs
CPython Docs
.. function:: inet_pton(address_family, ip_string) Convert an IP address from its family-specific string format to a packed, binary format. :func:`inet_pton` is useful when a library or network protocol calls for an object of type :c:struct:`in_addr` (similar to :func:`inet_aton`) or :c:struct:`in6_addr`.
.. function:: inet_pton(address_family, ip_string) Convert an IP address from its family-specific string format to a packed, binary format. :func:`inet_pton` is useful when a library or network protocol calls for an object of type :c:struct:`in_addr` (similar to :func:`inet_aton`) or :c:struct:`in6_addr`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
2fef1255-b96a-4057-a013-bd8f7dc0c13e
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,643
supabase-export-v2
a3733940d07dbc8f
in parallel, for example, using a `Happy Eyeballs`_ algorithm). In these cases, limiting the *type* and/or *proto* can help eliminate unsuccessful or unusable connection attempts. Some systems will, however, only return a single address. (For example, this was reported on Solaris and AIX configurations.) On these syst...
trusted_official_docs
CPython Docs
in parallel, for example, using a `Happy Eyeballs`_ algorithm). In these cases, limiting the *type* and/or *proto* can help eliminate unsuccessful or unusable connection attempts. Some systems will, however, only return a single address. (For example, this was reported on Solaris and AIX configurations.) On these syst...
in parallel, for example, using a `Happy Eyeballs`_ algorithm). In these cases, limiting the *type* and/or *proto* can help eliminate unsuccessful or unusable connection attempts. Some systems will, however, only return a single address. (For example, this was reported on Solaris and AIX configurations.) On these syst...
python, official-docs, cpython, P0
Local_Trusted_Corpus
30cf0aa9-35ce-493c-af05-6ec2925e0fac
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,586
supabase-export-v2
43c6abdae4956c8f
.. versionchanged:: 3.7 The CAN_ISOTP protocol was added. .. versionchanged:: 3.7 When :const:`SOCK_NONBLOCK` or :const:`SOCK_CLOEXEC` bit flags are applied to *type* they are cleared, and :attr:`socket.type` will not reflect them. They are still passed to the underlying system ``socket()`` call. Therefore,
trusted_official_docs
CPython Docs
.. versionchanged:: 3.7 The CAN_ISOTP protocol was added. .. versionchanged:: 3.7 When :const:`SOCK_NONBLOCK` or :const:`SOCK_CLOEXEC` bit flags are applied to *type* they are cleared, and :attr:`socket.type` will not reflect them. They are still passed to the underlying system ``socket()`` call. Therefore,
.. versionchanged:: 3.7 The CAN_ISOTP protocol was added. .. versionchanged:: 3.7 When :const:`SOCK_NONBLOCK` or :const:`SOCK_CLOEXEC` bit flags are applied to *type* they are cleared, and :attr:`socket.type` will not reflect them. They are still passed to the underlying system ``socket()`` call. Therefore,
python, official-docs, cpython, P0
Local_Trusted_Corpus
31133274-d9b0-419d-9f43-6a337445a7f3
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,930
supabase-export-v2
95a29242af8abb9f
Timeouts and the ``connect`` method ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ The :meth:`~socket.connect` operation is also subject to the timeout setting, and in general it is recommended to call :meth:`~socket.settimeout` before calling :meth:`~socket.connect` or pass a timeout parameter to :meth:`create_connection`. Howev...
trusted_official_docs
CPython Docs
Timeouts and the ``connect`` method ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ The :meth:`~socket.connect` operation is also subject to the timeout setting, and in general it is recommended to call :meth:`~socket.settimeout` before calling :meth:`~socket.connect` or pass a timeout parameter to :meth:`create_connection`. Howev...
Timeouts and the ``connect`` method ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ The :meth:`~socket.connect` operation is also subject to the timeout setting, and in general it is recommended to call :meth:`~socket.settimeout` before calling :meth:`~socket.connect` or pass a timeout parameter to :meth:`create_connection`. Howev...
python, official-docs, cpython, P0
Local_Trusted_Corpus
31a51d70-7986-4457-bff5-eb42cbc0db3f
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,579
supabase-export-v2
b2ebd226a4654179
and may be omitted or in the case where the address family is :const:`AF_CAN` the protocol should be one of :const:`CAN_RAW`, :const:`CAN_BCM`, :const:`CAN_ISOTP` or :const:`CAN_J1939`. If *fileno* is specified, the values for *family*, *type*, and *proto* are auto-detected from the specified file descriptor. Auto-det...
trusted_official_docs
CPython Docs
and may be omitted or in the case where the address family is :const:`AF_CAN` the protocol should be one of :const:`CAN_RAW`, :const:`CAN_BCM`, :const:`CAN_ISOTP` or :const:`CAN_J1939`. If *fileno* is specified, the values for *family*, *type*, and *proto* are auto-detected from the specified file descriptor. Auto-det...
and may be omitted or in the case where the address family is :const:`AF_CAN` the protocol should be one of :const:`CAN_RAW`, :const:`CAN_BCM`, :const:`CAN_ISOTP` or :const:`CAN_J1939`. If *fileno* is specified, the values for *family*, *type*, and *proto* are auto-detected from the specified file descriptor. Auto-det...
python, official-docs, cpython, P0
Local_Trusted_Corpus
32a22570-88e7-4895-b7d0-cf7d533d30bb
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,842
supabase-export-v2
cd11a89aedcf6eb3
.. method:: socket.recvfrom(bufsize[, flags]) Receive data from the socket. The return value is a pair ``(bytes, address)`` where *bytes* is a bytes object representing the data received and *address* is the address of the socket sending the data. See the Unix manual page :manpage:`recv(2)` for the meaning of the op...
trusted_official_docs
CPython Docs
.. method:: socket.recvfrom(bufsize[, flags]) Receive data from the socket. The return value is a pair ``(bytes, address)`` where *bytes* is a bytes object representing the data received and *address* is the address of the socket sending the data. See the Unix manual page :manpage:`recv(2)` for the meaning of the op...
.. method:: socket.recvfrom(bufsize[, flags]) Receive data from the socket. The return value is a pair ``(bytes, address)`` where *bytes* is a bytes object representing the data received and *address* is the address of the socket sending the data. See the Unix manual page :manpage:`recv(2)` for the meaning of the op...
python, official-docs, cpython, P0
Local_Trusted_Corpus
334ec45d-f824-4ecf-be8a-8bf69d07b1d4
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,867
supabase-export-v2
d489de2ab43ba5d6
some of the data was transmitted, the application needs to attempt delivery of the remaining data. For further information on this topic, consult the :ref:`socket-howto`. .. versionchanged:: 3.5 If the system call is interrupted and the signal handler does not raise an exception, the method now retries the system cal...
trusted_official_docs
CPython Docs
some of the data was transmitted, the application needs to attempt delivery of the remaining data. For further information on this topic, consult the :ref:`socket-howto`. .. versionchanged:: 3.5 If the system call is interrupted and the signal handler does not raise an exception, the method now retries the system cal...
some of the data was transmitted, the application needs to attempt delivery of the remaining data. For further information on this topic, consult the :ref:`socket-howto`. .. versionchanged:: 3.5 If the system call is interrupted and the signal handler does not raise an exception, the method now retries the system cal...
python, official-docs, cpython, P0
Local_Trusted_Corpus
33e5bc36-3449-4ba7-a708-4196939e154d
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,384
supabase-export-v2
65e0b8c7b17e88f4
representing a network interface name like ``'can0'``. The network interface name ``''`` can be used to receive packets from all network interfaces of this family. - :const:`CAN_ISOTP` protocol requires a tuple ``(interface, rx_addr, tx_addr)`` where both additional parameters are unsigned long integer that represent ...
trusted_official_docs
CPython Docs
representing a network interface name like ``'can0'``. The network interface name ``''`` can be used to receive packets from all network interfaces of this family. - :const:`CAN_ISOTP` protocol requires a tuple ``(interface, rx_addr, tx_addr)`` where both additional parameters are unsigned long integer that represent ...
representing a network interface name like ``'can0'``. The network interface name ``''`` can be used to receive packets from all network interfaces of this family. - :const:`CAN_ISOTP` protocol requires a tuple ``(interface, rx_addr, tx_addr)`` where both additional parameters are unsigned long integer that represent ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
380375e9-8122-445b-b4c8-9d14cb938374
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,944
supabase-export-v2
75dfacc6648dc7c3
# Echo server program import socket import sys HOST = None # Symbolic name meaning all available interfaces PORT = 50007 # Arbitrary non-privileged port s = None for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM, 0, socket.AI_PASSIVE): af, socktype, proto, canonname, sa = res try: s ...
trusted_official_docs
CPython Docs
# Echo server program import socket import sys HOST = None # Symbolic name meaning all available interfaces PORT = 50007 # Arbitrary non-privileged port s = None for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM, 0, socket.AI_PASSIVE): af, socktype, proto, canonname, sa = res try: s ...
# Echo server program import socket import sys HOST = None # Symbolic name meaning all available interfaces PORT = 50007 # Arbitrary non-privileged port s = None for res in socket.getaddrinfo(HOST, PORT, socket.AF_UNSPEC, socket.SOCK_STREAM, 0, socket.AI_PASSIVE): af, socktype, proto, canonname, sa = res try: s ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
3830354f-330e-4465-9e1e-2244a5acf236
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,973
supabase-export-v2
84e082ad0af664b9
This is because the previous execution has left the socket in a ``TIME_WAIT`` state, and can't be immediately reused. There is a :mod:`!socket` flag to set, in order to prevent this, :const:`socket.SO_REUSEADDR`::
trusted_official_docs
CPython Docs
This is because the previous execution has left the socket in a ``TIME_WAIT`` state, and can't be immediately reused. There is a :mod:`!socket` flag to set, in order to prevent this, :const:`socket.SO_REUSEADDR`::
This is because the previous execution has left the socket in a ``TIME_WAIT`` state, and can't be immediately reused. There is a :mod:`!socket` flag to set, in order to prevent this, :const:`socket.SO_REUSEADDR`::
python, official-docs, cpython, P0
Local_Trusted_Corpus
38ba1503-7c33-409e-a250-fd98abc1f1da
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,690
supabase-export-v2
b3751a739693f327
On machines where the host byte order is the same as network byte order, this is a no-op; otherwise, it performs a 2-byte swap operation. .. versionchanged:: 3.10 Raises :exc:`OverflowError` if *x* does not fit in a 16-bit unsigned integer.
trusted_official_docs
CPython Docs
On machines where the host byte order is the same as network byte order, this is a no-op; otherwise, it performs a 2-byte swap operation. .. versionchanged:: 3.10 Raises :exc:`OverflowError` if *x* does not fit in a 16-bit unsigned integer.
On machines where the host byte order is the same as network byte order, this is a no-op; otherwise, it performs a 2-byte swap operation. .. versionchanged:: 3.10 Raises :exc:`OverflowError` if *x* does not fit in a 16-bit unsigned integer.
python, official-docs, cpython, P0
Local_Trusted_Corpus
3a13292b-d2fd-4853-85f3-8be3ad3a6e58
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,414
supabase-export-v2
231de028a33621c0
services running on co-processors in Qualcomm platforms. The address family is represented as a ``(node, port)`` tuple where the *node* and *port* are non-negative integers. .. availability:: Linux >= 4.7.
trusted_official_docs
CPython Docs
services running on co-processors in Qualcomm platforms. The address family is represented as a ``(node, port)`` tuple where the *node* and *port* are non-negative integers. .. availability:: Linux >= 4.7.
services running on co-processors in Qualcomm platforms. The address family is represented as a ``(node, port)`` tuple where the *node* and *port* are non-negative integers. .. availability:: Linux >= 4.7.
python, official-docs, cpython, P0
Local_Trusted_Corpus
3a3bcc19-2b79-4b96-9b6c-d3fb14a0753d
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,460
supabase-export-v2
a93b9f19a56d05b1
.. data:: SO_* SOMAXCONN MSG_* SOL_* SCM_* IPPROTO_* IPPORT_* INADDR_* IP_* IPV6_* EAI_* AI_* NI_* TCP_* Many constants of these forms, documented in the Unix documentation on sockets and/or the IP protocol, are also defined in the socket module. They are generally used in arguments to the :meth:`~socket.setsockopt` ...
trusted_official_docs
CPython Docs
.. data:: SO_* SOMAXCONN MSG_* SOL_* SCM_* IPPROTO_* IPPORT_* INADDR_* IP_* IPV6_* EAI_* AI_* NI_* TCP_* Many constants of these forms, documented in the Unix documentation on sockets and/or the IP protocol, are also defined in the socket module. They are generally used in arguments to the :meth:`~socket.setsockopt` ...
.. data:: SO_* SOMAXCONN MSG_* SOL_* SCM_* IPPROTO_* IPPORT_* INADDR_* IP_* IPV6_* EAI_* AI_* NI_* TCP_* Many constants of these forms, documented in the Unix documentation on sockets and/or the IP protocol, are also defined in the socket module. They are generally used in arguments to the :meth:`~socket.setsockopt` ...
python, official-docs, cpython, P0
Local_Trusted_Corpus
3a759cd8-96eb-42a0-9a26-a4d8d93317aa
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,852
supabase-export-v2
cf4ea00a924d344a
import socket, array def recv_fds(sock, msglen, maxfds): fds = array.array("i") # Array of ints msg, ancdata, flags, addr = sock.recvmsg(msglen, socket.CMSG_LEN(maxfds * fds.itemsize)) for cmsg_level, cmsg_type, cmsg_data in ancdata: if cmsg_level == socket.SOL_SOCKET and cmsg_type == socket.SCM_RIGHTS: # Append d...
trusted_official_docs
CPython Docs
import socket, array def recv_fds(sock, msglen, maxfds): fds = array.array("i") # Array of ints msg, ancdata, flags, addr = sock.recvmsg(msglen, socket.CMSG_LEN(maxfds * fds.itemsize)) for cmsg_level, cmsg_type, cmsg_data in ancdata: if cmsg_level == socket.SOL_SOCKET and cmsg_type == socket.SCM_RIGHTS: # Append d...
import socket, array def recv_fds(sock, msglen, maxfds): fds = array.array("i") # Array of ints msg, ancdata, flags, addr = sock.recvmsg(msglen, socket.CMSG_LEN(maxfds * fds.itemsize)) for cmsg_level, cmsg_type, cmsg_data in ancdata: if cmsg_level == socket.SOL_SOCKET and cmsg_type == socket.SCM_RIGHTS: # Append d...
python, official-docs, cpython, P0
Local_Trusted_Corpus
3ac577e8-7b86-460c-9ac4-226ec3a2aac9
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,844
supabase-export-v2
f4c6450ad8f398c9
signal handler does not raise an exception, the method now retries the system call instead of raising an :exc:`InterruptedError` exception (see :pep:`475` for the rationale). .. versionchanged:: 3.7 For multicast IPv6 address, first item of *address* does not contain ``%scope_id`` part anymore. In order to get full I...
trusted_official_docs
CPython Docs
signal handler does not raise an exception, the method now retries the system call instead of raising an :exc:`InterruptedError` exception (see :pep:`475` for the rationale). .. versionchanged:: 3.7 For multicast IPv6 address, first item of *address* does not contain ``%scope_id`` part anymore. In order to get full I...
signal handler does not raise an exception, the method now retries the system call instead of raising an :exc:`InterruptedError` exception (see :pep:`475` for the rationale). .. versionchanged:: 3.7 For multicast IPv6 address, first item of *address* does not contain ``%scope_id`` part anymore. In order to get full I...
python, official-docs, cpython, P0
Local_Trusted_Corpus
3bf44647-83cd-40a6-9273-b1bb607cb705
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,452
supabase-export-v2
edc52c3e342ded6e
.. data:: SOCK_STREAM SOCK_DGRAM SOCK_RAW SOCK_RDM SOCK_SEQPACKET These constants represent the socket types, used for the second argument to :func:`~socket.socket`. More constants may be available depending on the system. (Only :const:`SOCK_STREAM` and :const:`SOCK_DGRAM` appear to be generally useful.)
trusted_official_docs
CPython Docs
.. data:: SOCK_STREAM SOCK_DGRAM SOCK_RAW SOCK_RDM SOCK_SEQPACKET These constants represent the socket types, used for the second argument to :func:`~socket.socket`. More constants may be available depending on the system. (Only :const:`SOCK_STREAM` and :const:`SOCK_DGRAM` appear to be generally useful.)
.. data:: SOCK_STREAM SOCK_DGRAM SOCK_RAW SOCK_RDM SOCK_SEQPACKET These constants represent the socket types, used for the second argument to :func:`~socket.socket`. More constants may be available depending on the system. (Only :const:`SOCK_STREAM` and :const:`SOCK_DGRAM` appear to be generally useful.)
python, official-docs, cpython, P0
Local_Trusted_Corpus
3ed3c8a5-40a4-43fc-93af-f1d427566bcd
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,931
supabase-export-v2
1ae101d867a434bc
parameter to :meth:`create_connection`. However, the system network stack may also return a connection timeout error of its own regardless of any Python socket timeout setting. Timeouts and the ``accept`` method ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
trusted_official_docs
CPython Docs
parameter to :meth:`create_connection`. However, the system network stack may also return a connection timeout error of its own regardless of any Python socket timeout setting. Timeouts and the ``accept`` method ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
parameter to :meth:`create_connection`. However, the system network stack may also return a connection timeout error of its own regardless of any Python socket timeout setting. Timeouts and the ``accept`` method ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
python, official-docs, cpython, P0
Local_Trusted_Corpus
3ffe00c6-002a-474b-9bed-c3a71015b52e
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,722
supabase-export-v2
2f69aab7677dab12
.. function:: CMSG_SPACE(length) Return the buffer size needed for :meth:`~socket.recvmsg` to receive an ancillary data item with associated data of the given *length*, along with any trailing padding. The buffer space needed to receive multiple items is the sum of the :func:`CMSG_SPACE` values for their associated...
trusted_official_docs
CPython Docs
.. function:: CMSG_SPACE(length) Return the buffer size needed for :meth:`~socket.recvmsg` to receive an ancillary data item with associated data of the given *length*, along with any trailing padding. The buffer space needed to receive multiple items is the sum of the :func:`CMSG_SPACE` values for their associated...
.. function:: CMSG_SPACE(length) Return the buffer size needed for :meth:`~socket.recvmsg` to receive an ancillary data item with associated data of the given *length*, along with any trailing padding. The buffer space needed to receive multiple items is the sum of the :func:`CMSG_SPACE` values for their associated...
python, official-docs, cpython, P0
Local_Trusted_Corpus
4102564d-fc32-454d-9f63-681a71c3f2b3
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,435
supabase-export-v2
db62c798bf29356b
error returned by a library call. *h_errno* is a numeric value, while *string* represents the description of *h_errno*, as returned by the :c:func:`hstrerror` C function. .. versionchanged:: 3.3 This class was made a subclass of :exc:`OSError`.
trusted_official_docs
CPython Docs
error returned by a library call. *h_errno* is a numeric value, while *string* represents the description of *h_errno*, as returned by the :c:func:`hstrerror` C function. .. versionchanged:: 3.3 This class was made a subclass of :exc:`OSError`.
error returned by a library call. *h_errno* is a numeric value, while *string* represents the description of *h_errno*, as returned by the :c:func:`hstrerror` C function. .. versionchanged:: 3.3 This class was made a subclass of :exc:`OSError`.
python, official-docs, cpython, P0
Local_Trusted_Corpus
43b2d645-39d2-4fc8-aab4-aa37bb9169a5
CPython Docs
file://datasets/cpython/Doc/library/socket.rst
unknown
84de57a2-f2b8-438d-a0a4-5acc38e81ff6
47,869
supabase-export-v2
d011c1d100a1d758
.. method:: socket.sendall(bytes[, flags]) Send data to the socket. The socket must be connected to a remote socket. The optional *flags* argument has the same meaning as for :meth:`recv`. Unlike :meth:`send`, this method continues to send data from *bytes* until either all data has been sent or an error occurs. ``No...
trusted_official_docs
CPython Docs
.. method:: socket.sendall(bytes[, flags]) Send data to the socket. The socket must be connected to a remote socket. The optional *flags* argument has the same meaning as for :meth:`recv`. Unlike :meth:`send`, this method continues to send data from *bytes* until either all data has been sent or an error occurs. ``No...
.. method:: socket.sendall(bytes[, flags]) Send data to the socket. The socket must be connected to a remote socket. The optional *flags* argument has the same meaning as for :meth:`recv`. Unlike :meth:`send`, this method continues to send data from *bytes* until either all data has been sent or an error occurs. ``No...
python, official-docs, cpython, P0
Local_Trusted_Corpus