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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
b9ccde27-28cf-4b69-9480-89104aba0b35 | CPython Docs | file://datasets/cpython/Doc/library/tokenize.rst | unknown | bcf6704d-8f4c-4f1a-9fea-374d832bdca3 | 32,060 | supabase-export-v2 | 6d0ff513d25b5380 | lossless and round-trips are assured. The guarantee applies only to the token type and token string as the spacing between tokens (column positions) may change.
It returns bytes, encoded using the :data:`~token.ENCODING` token, which
is the first token sequence output by :func:`.tokenize`. If there is no
encoding tok... | trusted_official_docs | CPython Docs | lossless and round-trips are assured. The guarantee applies only to the token type and token string as the spacing between tokens (column positions) may change.
It returns bytes, encoded using the :data:`~token.ENCODING` token, which
is the first token sequence output by :func:`.tokenize`. If there is no
encoding tok... | lossless and round-trips are assured. The guarantee applies only to the token type and token string as the spacing between tokens (column positions) may change.
It returns bytes, encoded using the :data:`~token.ENCODING` token, which
is the first token sequence output by :func:`.tokenize`. If there is no
encoding tok... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c1002cbb-875f-4c0e-abd0-fc9a99213523 | CPython Docs | file://datasets/cpython/Doc/library/tokenize.rst | unknown | bcf6704d-8f4c-4f1a-9fea-374d832bdca3 | 32,084 | supabase-export-v2 | 7cbe04e753aae053 | If :file:`filename.py` is specified its contents are tokenized to stdout. Otherwise, tokenization is performed on stdin.
.. versionadded:: next
Output is in color by default and can be
:ref:`controlled using environment variables <using-on-controlling-color>`. | trusted_official_docs | CPython Docs | If :file:`filename.py` is specified its contents are tokenized to stdout. Otherwise, tokenization is performed on stdin.
.. versionadded:: next
Output is in color by default and can be
:ref:`controlled using environment variables <using-on-controlling-color>`. | If :file:`filename.py` is specified its contents are tokenized to stdout. Otherwise, tokenization is performed on stdin.
.. versionadded:: next
Output is in color by default and can be
:ref:`controlled using environment variables <using-on-controlling-color>`. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c1d7da64-7336-4e85-a422-6e64ba5fe64d | CPython Docs | file://datasets/cpython/Doc/library/tokenize.rst | unknown | bcf6704d-8f4c-4f1a-9fea-374d832bdca3 | 32,090 | supabase-export-v2 | 9317bbb2ff2fe6c0 | >>> from decimal import Decimal >>> s = 'print(+21.3e-5*-.1234/81.7)' >>> decistmt(s) "print (+Decimal ('21.3e-5')*-Decimal ('.1234')/Decimal ('81.7'))"
The format of the exponent is inherited from the platform C library. Known cases are "e-007" (Windows) and "e-07" (not Windows). Since
we're only showing 12 digits, a... | trusted_official_docs | CPython Docs | >>> from decimal import Decimal >>> s = 'print(+21.3e-5*-.1234/81.7)' >>> decistmt(s) "print (+Decimal ('21.3e-5')*-Decimal ('.1234')/Decimal ('81.7'))"
The format of the exponent is inherited from the platform C library. Known cases are "e-007" (Windows) and "e-07" (not Windows). Since
we're only showing 12 digits, a... | >>> from decimal import Decimal >>> s = 'print(+21.3e-5*-.1234/81.7)' >>> decistmt(s) "print (+Decimal ('21.3e-5')*-Decimal ('.1234')/Decimal ('81.7'))"
The format of the exponent is inherited from the platform C library. Known cases are "e-007" (Windows) and "e-07" (not Windows). Since
we're only showing 12 digits, a... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
d38dcba1-93f1-4793-941d-d954b1e52ece | CPython Docs | file://datasets/cpython/Doc/library/tokenize.rst | unknown | bcf6704d-8f4c-4f1a-9fea-374d832bdca3 | 32,041 | supabase-export-v2 | 44d3ca142f38bcb0 | .. warning::
Note that the functions in this module are only designed to parse
syntactically valid Python code (code that does not raise when parsed
using :func:`ast.parse`). The behavior of the functions in this module is
**undefined** when providing invalid Python code and it can change at any
point. | trusted_official_docs | CPython Docs | .. warning::
Note that the functions in this module are only designed to parse
syntactically valid Python code (code that does not raise when parsed
using :func:`ast.parse`). The behavior of the functions in this module is
**undefined** when providing invalid Python code and it can change at any
point. | .. warning::
Note that the functions in this module are only designed to parse
syntactically valid Python code (code that does not raise when parsed
using :func:`ast.parse`). The behavior of the functions in this module is
**undefined** when providing invalid Python code and it can change at any
point. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
dbf65297-5e3e-46c8-9151-b5c5dfc5f6fd | CPython Docs | file://datasets/cpython/Doc/library/tokenize.rst | unknown | bcf6704d-8f4c-4f1a-9fea-374d832bdca3 | 32,065 | supabase-export-v2 | aebcc996c5bd078c | maximum of twice, and return the encoding used (as a string) and a list of any lines (not decoded from bytes) it has read in.
It detects the encoding from the presence of a UTF-8 BOM or an encoding
cookie as specified in :pep:`263`. If both a BOM and a cookie are present,
but disagree, a :exc:`SyntaxError` will be ra... | trusted_official_docs | CPython Docs | maximum of twice, and return the encoding used (as a string) and a list of any lines (not decoded from bytes) it has read in.
It detects the encoding from the presence of a UTF-8 BOM or an encoding
cookie as specified in :pep:`263`. If both a BOM and a cookie are present,
but disagree, a :exc:`SyntaxError` will be ra... | maximum of twice, and return the encoding used (as a string) and a list of any lines (not decoded from bytes) it has read in.
It detects the encoding from the presence of a UTF-8 BOM or an encoding
cookie as specified in :pep:`263`. If both a BOM and a cookie are present,
but disagree, a :exc:`SyntaxError` will be ra... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
eaa35885-6e31-4c26-83df-71075c251f4a | CPython Docs | file://datasets/cpython/Doc/library/tokenize.rst | unknown | bcf6704d-8f4c-4f1a-9fea-374d832bdca3 | 32,039 | supabase-export-v2 | 9208b5b9ff30f90f | implemented in Python. The scanner in this module returns comments as tokens as well, making it useful for implementing "pretty-printers", including colorizers for on-screen displays.
To simplify token stream handling, all :ref:`operator <operators>` and
:ref:`delimiter <delimiters>` tokens and :data:`Ellipsis` are ret... | trusted_official_docs | CPython Docs | implemented in Python. The scanner in this module returns comments as tokens as well, making it useful for implementing "pretty-printers", including colorizers for on-screen displays.
To simplify token stream handling, all :ref:`operator <operators>` and
:ref:`delimiter <delimiters>` tokens and :data:`Ellipsis` are ret... | implemented in Python. The scanner in this module returns comments as tokens as well, making it useful for implementing "pretty-printers", including colorizers for on-screen displays.
To simplify token stream handling, all :ref:`operator <operators>` and
:ref:`delimiter <delimiters>` tokens and :data:`Ellipsis` are ret... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ee207be1-44cd-4c21-91ab-d36b986f66b7 | CPython Docs | file://datasets/cpython/Doc/library/tokenize.rst | unknown | bcf6704d-8f4c-4f1a-9fea-374d832bdca3 | 32,059 | supabase-export-v2 | f6b473a8cd6d4297 | source code. The *iterable* must return sequences with at least two elements, the token type and the token string. Any additional sequence elements are ignored.
The result is guaranteed to tokenize back to match the input so that the
conversion is lossless and round-trips are assured. The guarantee applies
only to th... | trusted_official_docs | CPython Docs | source code. The *iterable* must return sequences with at least two elements, the token type and the token string. Any additional sequence elements are ignored.
The result is guaranteed to tokenize back to match the input so that the
conversion is lossless and round-trips are assured. The guarantee applies
only to th... | source code. The *iterable* must return sequences with at least two elements, the token type and the token string. Any additional sequence elements are ignored.
The result is guaranteed to tokenize back to match the input so that the
conversion is lossless and round-trips are assured. The guarantee applies
only to th... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f6c8c28c-be09-415a-b7c2-408718f98407 | CPython Docs | file://datasets/cpython/Doc/library/tokenize.rst | unknown | bcf6704d-8f4c-4f1a-9fea-374d832bdca3 | 32,048 | supabase-export-v2 | 6386b8bd08f5777a | additional property named ``exact_type`` that contains the exact operator type for :data:`~token.OP` tokens. For all other token types ``exact_type`` equals the named tuple ``type`` field.
.. versionchanged:: 3.1
Added support for named tuples. | trusted_official_docs | CPython Docs | additional property named ``exact_type`` that contains the exact operator type for :data:`~token.OP` tokens. For all other token types ``exact_type`` equals the named tuple ``type`` field.
.. versionchanged:: 3.1
Added support for named tuples. | additional property named ``exact_type`` that contains the exact operator type for :data:`~token.OP` tokens. For all other token types ``exact_type`` equals the named tuple ``type`` field.
.. versionchanged:: 3.1
Added support for named tuples. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f1a2bc37-9327-4b04-9c52-5054625632d9 | CPython Docs | file://datasets/cpython/Doc/library/debug.rst | unknown | 3df1cc9b-0446-46ab-abc0-c3e2a88fa35f | 32,110 | supabase-export-v2 | 30218e29da7a7832 | *********************** Debugging and profiling ***********************
These libraries help you with Python development: the debugger enables you to
step through code, analyze stack frames and set breakpoints etc., and the
profilers run code and give you a detailed breakdown of execution times,
allowing you to identif... | trusted_official_docs | CPython Docs | *********************** Debugging and profiling ***********************
These libraries help you with Python development: the debugger enables you to
step through code, analyze stack frames and set breakpoints etc., and the
profilers run code and give you a detailed breakdown of execution times,
allowing you to identif... | *********************** Debugging and profiling ***********************
These libraries help you with Python development: the debugger enables you to
step through code, analyze stack frames and set breakpoints etc., and the
profilers run code and give you a detailed breakdown of execution times,
allowing you to identif... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
26ee9477-8567-4d9f-a923-6e57a4f09142 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,133 | supabase-export-v2 | 30bf2d4edecdde8d | .. versionchanged:: 3.12 Space is allowed around the slash for string inputs: ``Fraction('2 / 3')``.
.. versionchanged:: 3.12
:class:`Fraction` instances now support float-style formatting, with
presentation types ``"e"``, ``"E"``, ``"f"``, ``"F"``, ``"g"``, ``"G"``
and ``"%""``. | trusted_official_docs | CPython Docs | .. versionchanged:: 3.12 Space is allowed around the slash for string inputs: ``Fraction('2 / 3')``.
.. versionchanged:: 3.12
:class:`Fraction` instances now support float-style formatting, with
presentation types ``"e"``, ``"E"``, ``"f"``, ``"F"``, ``"g"``, ``"G"``
and ``"%""``. | .. versionchanged:: 3.12 Space is allowed around the slash for string inputs: ``Fraction('2 / 3')``.
.. versionchanged:: 3.12
:class:`Fraction` instances now support float-style formatting, with
presentation types ``"e"``, ``"E"``, ``"f"``, ``"F"``, ``"g"``, ``"G"``
and ``"%""``. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
3a389f84-f343-4004-aa2c-7deecf5d150c | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,173 | supabase-export-v2 | 54a24e54217f4216 | Here are some examples::
>>> from fractions import Fraction
>>> format(Fraction(103993, 33102), '_')
'103_993/33_102'
>>> format(Fraction(1, 7), '.^+10')
'...+1/7...'
>>> format(Fraction(3, 1), '')
'3'
>>> format(Fraction(3, 1), '#')
'3/1'
>>> format(Fraction(1, 7), '.40g')
'0.14285714285714285714285714285714... | trusted_official_docs | CPython Docs | Here are some examples::
>>> from fractions import Fraction
>>> format(Fraction(103993, 33102), '_')
'103_993/33_102'
>>> format(Fraction(1, 7), '.^+10')
'...+1/7...'
>>> format(Fraction(3, 1), '')
'3'
>>> format(Fraction(3, 1), '#')
'3/1'
>>> format(Fraction(1, 7), '.40g')
'0.14285714285714285714285714285714... | Here are some examples::
>>> from fractions import Fraction
>>> format(Fraction(103993, 33102), '_')
'103_993/33_102'
>>> format(Fraction(1, 7), '.^+10')
'...+1/7...'
>>> format(Fraction(3, 1), '')
'3'
>>> format(Fraction(3, 1), '#')
'3/1'
>>> format(Fraction(1, 7), '.40g')
'0.14285714285714285714285714285714... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
4738f1b1-50d7-4700-952d-629da6d1c82e | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,135 | supabase-export-v2 | 0273af54c04ec024 | .. versionchanged:: 3.13 Formatting of :class:`Fraction` instances without a presentation type now supports fill, alignment, sign handling, minimum width and grouping.
.. versionchanged:: 3.14
The :class:`Fraction` constructor now accepts any objects with the
:meth:`!as_integer_ratio` method. | trusted_official_docs | CPython Docs | .. versionchanged:: 3.13 Formatting of :class:`Fraction` instances without a presentation type now supports fill, alignment, sign handling, minimum width and grouping.
.. versionchanged:: 3.14
The :class:`Fraction` constructor now accepts any objects with the
:meth:`!as_integer_ratio` method. | .. versionchanged:: 3.13 Formatting of :class:`Fraction` instances without a presentation type now supports fill, alignment, sign handling, minimum width and grouping.
.. versionchanged:: 3.14
The :class:`Fraction` constructor now accepts any objects with the
:meth:`!as_integer_ratio` method. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
4752101b-fe72-4cca-ab16-81a6e8a24234 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,129 | supabase-export-v2 | 4aa46d77ce0670fa | .. versionchanged:: 3.2 The :class:`Fraction` constructor now accepts :class:`float` and :class:`decimal.Decimal` instances.
.. versionchanged:: 3.9
The :func:`math.gcd` function is now used to normalize the *numerator*
and *denominator*. :func:`math.gcd` always returns an :class:`int` type. Previously, the GCD type ... | trusted_official_docs | CPython Docs | .. versionchanged:: 3.2 The :class:`Fraction` constructor now accepts :class:`float` and :class:`decimal.Decimal` instances.
.. versionchanged:: 3.9
The :func:`math.gcd` function is now used to normalize the *numerator*
and *denominator*. :func:`math.gcd` always returns an :class:`int` type. Previously, the GCD type ... | .. versionchanged:: 3.2 The :class:`Fraction` constructor now accepts :class:`float` and :class:`decimal.Decimal` instances.
.. versionchanged:: 3.9
The :func:`math.gcd` function is now used to normalize the *numerator*
and *denominator*. :func:`math.gcd` always returns an :class:`int` type. Previously, the GCD type ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
52ecfa60-cc02-4ec9-9669-35d8d6685b40 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,167 | supabase-export-v2 | b2c08afcd47718a3 | .. method:: __round__() __round__(ndigits)
The first version returns the nearest :class:`int` to ``self``,
rounding half to even. The second version rounds ``self`` to the
nearest multiple of ``Fraction(1, 10**ndigits)`` (logically, if
``ndigits`` is negative), again rounding half toward even. This
method can also ... | trusted_official_docs | CPython Docs | .. method:: __round__() __round__(ndigits)
The first version returns the nearest :class:`int` to ``self``,
rounding half to even. The second version rounds ``self`` to the
nearest multiple of ``Fraction(1, 10**ndigits)`` (logically, if
``ndigits`` is negative), again rounding half toward even. This
method can also ... | .. method:: __round__() __round__(ndigits)
The first version returns the nearest :class:`int` to ``self``,
rounding half to even. The second version rounds ``self`` to the
nearest multiple of ``Fraction(1, 10**ndigits)`` (logically, if
``ndigits`` is negative), again rounding half toward even. This
method can also ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
5a59e73b-50be-4f66-b94c-98479e2d2ffb | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,125 | supabase-export-v2 | fc90899a3c16bc01 | [sign] numerator ['/' denominator]
where the optional ``sign`` may be either '+' or '-' and
``numerator`` and ``denominator`` (if present) are strings of
decimal digits (underscores may be used to delimit digits as with
integral literals in code). In addition, any string that represents a finite
value and is accept... | trusted_official_docs | CPython Docs | [sign] numerator ['/' denominator]
where the optional ``sign`` may be either '+' or '-' and
``numerator`` and ``denominator`` (if present) are strings of
decimal digits (underscores may be used to delimit digits as with
integral literals in code). In addition, any string that represents a finite
value and is accept... | [sign] numerator ['/' denominator]
where the optional ``sign`` may be either '+' or '-' and
``numerator`` and ``denominator`` (if present) are strings of
decimal digits (underscores may be used to delimit digits as with
integral literals in code). In addition, any string that represents a finite
value and is accept... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
5a92bf36-f0ad-4b98-9e2a-190002b4334a | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,130 | supabase-export-v2 | 88bf386cbe9bab58 | function is now used to normalize the *numerator* and *denominator*. :func:`math.gcd` always returns an :class:`int` type. Previously, the GCD type depended on *numerator* and *denominator*.
.. versionchanged:: 3.11
Underscores are now permitted when creating a :class:`Fraction` instance
from a string, following :PEP... | trusted_official_docs | CPython Docs | function is now used to normalize the *numerator* and *denominator*. :func:`math.gcd` always returns an :class:`int` type. Previously, the GCD type depended on *numerator* and *denominator*.
.. versionchanged:: 3.11
Underscores are now permitted when creating a :class:`Fraction` instance
from a string, following :PEP... | function is now used to normalize the *numerator* and *denominator*. :func:`math.gcd` always returns an :class:`int` type. Previously, the GCD type depended on *numerator* and *denominator*.
.. versionchanged:: 3.11
Underscores are now permitted when creating a :class:`Fraction` instance
from a string, following :PEP... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
5e3f8d17-f979-427e-9ffd-9dfa437f735c | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,126 | supabase-export-v2 | e26c9e585a29a866 | constructor is also accepted by the :class:`Fraction` constructor. In either form the input string may also have leading and/or trailing whitespace. Here are some examples::
>>> from fractions import Fraction
>>> Fraction(16, -10)
Fraction(-8, 5)
>>> Fraction(123)
Fraction(123, 1)
>>> Fraction()
Fraction(0, 1)
>... | trusted_official_docs | CPython Docs | constructor is also accepted by the :class:`Fraction` constructor. In either form the input string may also have leading and/or trailing whitespace. Here are some examples::
>>> from fractions import Fraction
>>> Fraction(16, -10)
Fraction(-8, 5)
>>> Fraction(123)
Fraction(123, 1)
>>> Fraction()
Fraction(0, 1)
>... | constructor is also accepted by the :class:`Fraction` constructor. In either form the input string may also have leading and/or trailing whitespace. Here are some examples::
>>> from fractions import Fraction
>>> Fraction(16, -10)
Fraction(-8, 5)
>>> Fraction(123)
Fraction(123, 1)
>>> Fraction()
Fraction(0, 1)
>... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
77acac26-7e0e-4a5e-9965-ba3ec1b99900 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,127 | supabase-export-v2 | 3d503b24ce39b60f | >>> Fraction('-.125') Fraction(-1, 8) >>> Fraction('7e-6') Fraction(7, 1000000) >>> Fraction(2.25) Fraction(9, 4) >>> Fraction(1.1) Fraction(2476979795053773, 2251799813685248) >>> from decimal import Decimal >>> Fraction(Decimal('1.1')) Fraction(11, 10)
The :class:`Fraction` class inherits from the abstract base class... | trusted_official_docs | CPython Docs | >>> Fraction('-.125') Fraction(-1, 8) >>> Fraction('7e-6') Fraction(7, 1000000) >>> Fraction(2.25) Fraction(9, 4) >>> Fraction(1.1) Fraction(2476979795053773, 2251799813685248) >>> from decimal import Decimal >>> Fraction(Decimal('1.1')) Fraction(11, 10)
The :class:`Fraction` class inherits from the abstract base class... | >>> Fraction('-.125') Fraction(-1, 8) >>> Fraction('7e-6') Fraction(7, 1000000) >>> Fraction(2.25) Fraction(9, 4) >>> Fraction(1.1) Fraction(2476979795053773, 2251799813685248) >>> from decimal import Decimal >>> Fraction(Decimal('1.1')) Fraction(11, 10)
The :class:`Fraction` class inherits from the abstract base class... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
9ba2c99b-2606-4c38-a742-689a334e7c1f | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,170 | supabase-export-v2 | 555d69e1ff19acb5 | Provides support for formatting of :class:`Fraction` instances via the :meth:`str.format` method, the :func:`format` built-in function, or :ref:`Formatted string literals <f-strings>`.
If the ``format_spec`` format specification string does not end with one
of the presentation types ``'e'``, ``'E'``, ``'f'``, ``'F'``,... | trusted_official_docs | CPython Docs | Provides support for formatting of :class:`Fraction` instances via the :meth:`str.format` method, the :func:`format` built-in function, or :ref:`Formatted string literals <f-strings>`.
If the ``format_spec`` format specification string does not end with one
of the presentation types ``'e'``, ``'E'``, ``'f'``, ``'F'``,... | Provides support for formatting of :class:`Fraction` instances via the :meth:`str.format` method, the :func:`format` built-in function, or :ref:`Formatted string literals <f-strings>`.
If the ``format_spec`` format specification string does not end with one
of the presentation types ``'e'``, ``'E'``, ``'f'``, ``'F'``,... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
a8768daf-18ef-4c5c-8f00-c80d8d047519 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,121 | supabase-export-v2 | 2230896523575b21 | .. class:: Fraction(numerator=0, denominator=1) Fraction(number) Fraction(string)
The first version requires that *numerator* and *denominator* are instances
of :class:`numbers.Rational` and returns a new :class:`Fraction` instance
with a value equal to ``numerator/denominator``. If *denominator* is zero, it raises a... | trusted_official_docs | CPython Docs | .. class:: Fraction(numerator=0, denominator=1) Fraction(number) Fraction(string)
The first version requires that *numerator* and *denominator* are instances
of :class:`numbers.Rational` and returns a new :class:`Fraction` instance
with a value equal to ``numerator/denominator``. If *denominator* is zero, it raises a... | .. class:: Fraction(numerator=0, denominator=1) Fraction(number) Fraction(string)
The first version requires that *numerator* and *denominator* are instances
of :class:`numbers.Rational` and returns a new :class:`Fraction` instance
with a value equal to ``numerator/denominator``. If *denominator* is zero, it raises a... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c9be2ccf-6d58-4a5e-9c56-3dc25db6da74 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,122 | supabase-export-v2 | 87047bae0e28f63a | *denominator* are instances of :class:`numbers.Rational` and returns a new :class:`Fraction` instance with a value equal to ``numerator/denominator``. If *denominator* is zero, it raises a :exc:`ZeroDivisionError`.
The second version requires that *number* is an instance of
:class:`numbers.Rational` or has the :meth:`... | trusted_official_docs | CPython Docs | *denominator* are instances of :class:`numbers.Rational` and returns a new :class:`Fraction` instance with a value equal to ``numerator/denominator``. If *denominator* is zero, it raises a :exc:`ZeroDivisionError`.
The second version requires that *number* is an instance of
:class:`numbers.Rational` or has the :meth:`... | *denominator* are instances of :class:`numbers.Rational` and returns a new :class:`Fraction` instance with a value equal to ``numerator/denominator``. If *denominator* is zero, it raises a :exc:`ZeroDivisionError`.
The second version requires that *number* is an instance of
:class:`numbers.Rational` or has the :meth:`... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
d0021069-a05b-44aa-809b-33e16440cc23 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,158 | supabase-export-v2 | fce79f1a6c4c5fdc | returns the closest :class:`Fraction` to ``self`` that has denominator at most max_denominator. This method is useful for finding rational approximations to a given floating-point number:
>>> from fractions import Fraction
>>> Fraction('3.1415926535897932').limit_denominator(1000)
Fraction(355, 113) | trusted_official_docs | CPython Docs | returns the closest :class:`Fraction` to ``self`` that has denominator at most max_denominator. This method is useful for finding rational approximations to a given floating-point number:
>>> from fractions import Fraction
>>> Fraction('3.1415926535897932').limit_denominator(1000)
Fraction(355, 113) | returns the closest :class:`Fraction` to ``self`` that has denominator at most max_denominator. This method is useful for finding rational approximations to a given floating-point number:
>>> from fractions import Fraction
>>> Fraction('3.1415926535897932').limit_denominator(1000)
Fraction(355, 113) | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
d9c3cf20-814a-41e0-8252-322908e61d11 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,123 | supabase-export-v2 | 7450d41c6eb690e3 | exactly equal to 11/10, and so ``Fraction(1.1)`` does *not* return ``Fraction(11, 10)`` as one might expect. (But see the documentation for the :meth:`limit_denominator` method below.)
The last version of the constructor expects a string. The usual form for this instance is:: | trusted_official_docs | CPython Docs | exactly equal to 11/10, and so ``Fraction(1.1)`` does *not* return ``Fraction(11, 10)`` as one might expect. (But see the documentation for the :meth:`limit_denominator` method below.)
The last version of the constructor expects a string. The usual form for this instance is:: | exactly equal to 11/10, and so ``Fraction(1.1)`` does *not* return ``Fraction(11, 10)`` as one might expect. (But see the documentation for the :meth:`limit_denominator` method below.)
The last version of the constructor expects a string. The usual form for this instance is:: | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
e3303d8f-c90d-486e-adef-50e73365e807 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,131 | supabase-export-v2 | da9f2d4d8270ee7c | .. versionchanged:: 3.11 Underscores are now permitted when creating a :class:`Fraction` instance from a string, following :PEP:`515` rules.
.. versionchanged:: 3.11
:class:`Fraction` implements ``__int__`` now to satisfy
``typing.SupportsInt`` instance checks. | trusted_official_docs | CPython Docs | .. versionchanged:: 3.11 Underscores are now permitted when creating a :class:`Fraction` instance from a string, following :PEP:`515` rules.
.. versionchanged:: 3.11
:class:`Fraction` implements ``__int__`` now to satisfy
``typing.SupportsInt`` instance checks. | .. versionchanged:: 3.11 Underscores are now permitted when creating a :class:`Fraction` instance from a string, following :PEP:`515` rules.
.. versionchanged:: 3.11
:class:`Fraction` implements ``__int__`` now to satisfy
``typing.SupportsInt`` instance checks. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
e5101e65-d6e7-4965-bd09-45458b9ef375 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,134 | supabase-export-v2 | b5c7044e383220ea | .. versionchanged:: 3.12 :class:`Fraction` instances now support float-style formatting, with presentation types ``"e"``, ``"E"``, ``"f"``, ``"F"``, ``"g"``, ``"G"`` and ``"%""``.
.. versionchanged:: 3.13
Formatting of :class:`Fraction` instances without a presentation type
now supports fill, alignment, sign handling... | trusted_official_docs | CPython Docs | .. versionchanged:: 3.12 :class:`Fraction` instances now support float-style formatting, with presentation types ``"e"``, ``"E"``, ``"f"``, ``"F"``, ``"g"``, ``"G"`` and ``"%""``.
.. versionchanged:: 3.13
Formatting of :class:`Fraction` instances without a presentation type
now supports fill, alignment, sign handling... | .. versionchanged:: 3.12 :class:`Fraction` instances now support float-style formatting, with presentation types ``"e"``, ``"E"``, ``"f"``, ``"F"``, ``"g"``, ``"G"`` and ``"%""``.
.. versionchanged:: 3.13
Formatting of :class:`Fraction` instances without a presentation type
now supports fill, alignment, sign handling... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
e6171f0c-943a-4edd-925a-1001bd9d9ad5 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,128 | supabase-export-v2 | 6dab209cf17d7cb4 | methods and operations from that class. :class:`Fraction` instances are :term:`hashable`, and should be treated as immutable. In addition, :class:`Fraction` has the following properties and methods:
.. versionchanged:: 3.2
The :class:`Fraction` constructor now accepts :class:`float` and
:class:`decimal.Decimal` insta... | trusted_official_docs | CPython Docs | methods and operations from that class. :class:`Fraction` instances are :term:`hashable`, and should be treated as immutable. In addition, :class:`Fraction` has the following properties and methods:
.. versionchanged:: 3.2
The :class:`Fraction` constructor now accepts :class:`float` and
:class:`decimal.Decimal` insta... | methods and operations from that class. :class:`Fraction` instances are :term:`hashable`, and should be treated as immutable. In addition, :class:`Fraction` has the following properties and methods:
.. versionchanged:: 3.2
The :class:`Fraction` constructor now accepts :class:`float` and
:class:`decimal.Decimal` insta... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
eca3abcb-d86f-4ae7-85a2-507d8d76ae7b | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,157 | supabase-export-v2 | 0bc6669930266e92 | .. method:: limit_denominator(max_denominator=1000000)
Finds and returns the closest :class:`Fraction` to ``self`` that has
denominator at most max_denominator. This method is useful for finding
rational approximations to a given floating-point number: | trusted_official_docs | CPython Docs | .. method:: limit_denominator(max_denominator=1000000)
Finds and returns the closest :class:`Fraction` to ``self`` that has
denominator at most max_denominator. This method is useful for finding
rational approximations to a given floating-point number: | .. method:: limit_denominator(max_denominator=1000000)
Finds and returns the closest :class:`Fraction` to ``self`` that has
denominator at most max_denominator. This method is useful for finding
rational approximations to a given floating-point number: | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f0c115c0-db51-4ede-a58b-db465c8b5827 | CPython Docs | file://datasets/cpython/Doc/library/fractions.rst | unknown | 53af08e9-2389-4296-9680-367ff5c1b3f8 | 32,171 | supabase-export-v2 | ff25d3db1bf42161 | output string to always include an explicit denominator, even when the value being formatted is an exact integer. The zero-fill flag ``'0'`` is not supported.
If the ``format_spec`` format specification string ends with one of
the presentation types ``'e'``, ``'E'``, ``'f'``, ``'F'``, ``'g'``,
``'G'`` or ``'%'`` then... | trusted_official_docs | CPython Docs | output string to always include an explicit denominator, even when the value being formatted is an exact integer. The zero-fill flag ``'0'`` is not supported.
If the ``format_spec`` format specification string ends with one of
the presentation types ``'e'``, ``'E'``, ``'f'``, ``'F'``, ``'g'``,
``'G'`` or ``'%'`` then... | output string to always include an explicit denominator, even when the value being formatted is an exact integer. The zero-fill flag ``'0'`` is not supported.
If the ``format_spec`` format specification string ends with one of
the presentation types ``'e'``, ``'E'``, ``'f'``, ``'F'``, ``'g'``,
``'G'`` or ``'%'`` then... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
0c5d2755-de21-4b43-8438-4b44bb7a3a66 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,280 | supabase-export-v2 | 2fc734d302f8543f | authentication methods that support it, an "initial response" as specified in :rfc:`4954` can be sent along with the ``AUTH`` command, rather than requiring a challenge/response.
.. versionchanged:: 3.5
:exc:`SMTPNotSupportedError` may be raised, and the
*initial_response_ok* parameter was added. | trusted_official_docs | CPython Docs | authentication methods that support it, an "initial response" as specified in :rfc:`4954` can be sent along with the ``AUTH`` command, rather than requiring a challenge/response.
.. versionchanged:: 3.5
:exc:`SMTPNotSupportedError` may be raised, and the
*initial_response_ok* parameter was added. | authentication methods that support it, an "initial response" as specified in :rfc:`4954` can be sent along with the ``AUTH`` command, rather than requiring a challenge/response.
.. versionchanged:: 3.5
:exc:`SMTPNotSupportedError` may be raised, and the
*initial_response_ok* parameter was added. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
1125049d-3427-4e06-864f-b3aee77f42e0 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,283 | supabase-export-v2 | ea5197bcb16f6bda | Issue an ``SMTP`` ``AUTH`` command for the specified authentication *mechanism*, and handle the challenge response via *authobject*.
*mechanism* specifies which authentication mechanism is to
be used as argument to the ``AUTH`` command; the valid values are
those listed in the ``auth`` element of :attr:`esmtp_feature... | trusted_official_docs | CPython Docs | Issue an ``SMTP`` ``AUTH`` command for the specified authentication *mechanism*, and handle the challenge response via *authobject*.
*mechanism* specifies which authentication mechanism is to
be used as argument to the ``AUTH`` command; the valid values are
those listed in the ``auth`` element of :attr:`esmtp_feature... | Issue an ``SMTP`` ``AUTH`` command for the specified authentication *mechanism*, and handle the challenge response via *authobject*.
*mechanism* specifies which authentication mechanism is to
be used as argument to the ``AUTH`` command; the valid values are
those listed in the ``auth`` element of :attr:`esmtp_feature... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
13e0821c-06f1-4cb4-ac95-c419ac86c07c | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,288 | supabase-export-v2 | c5bfe1148f81da4b | *challenge* argument it is passed will be a ``bytes``. It should return ASCII ``str`` *data* that will be base64 encoded and sent to the server.
The ``SMTP`` class provides ``authobjects`` for the ``CRAM-MD5``, ``PLAIN``,
and ``LOGIN`` mechanisms; they are named ``SMTP.auth_cram_md5``,
``SMTP.auth_plain``, and ``SMTP... | trusted_official_docs | CPython Docs | *challenge* argument it is passed will be a ``bytes``. It should return ASCII ``str`` *data* that will be base64 encoded and sent to the server.
The ``SMTP`` class provides ``authobjects`` for the ``CRAM-MD5``, ``PLAIN``,
and ``LOGIN`` mechanisms; they are named ``SMTP.auth_cram_md5``,
``SMTP.auth_plain``, and ``SMTP... | *challenge* argument it is passed will be a ``bytes``. It should return ASCII ``str`` *data* that will be base64 encoded and sent to the server.
The ``SMTP`` class provides ``authobjects`` for the ``CRAM-MD5``, ``PLAIN``,
and ``LOGIN`` mechanisms; they are named ``SMTP.auth_cram_md5``,
``SMTP.auth_plain``, and ``SMTP... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
164d5e86-fe57-4df5-a380-dc3294de340c | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,202 | supabase-export-v2 | 32431c61d41f2c22 | is set to a truthy value, :meth:`SMTP.connect` is called with host and port automatically when the object is created; otherwise, :meth:`!SMTP.connect` must be called manually.
The optional arguments *local_hostname*, *timeout* and *source_address* have the same
meaning as they do in the :class:`SMTP` class. *context*,... | trusted_official_docs | CPython Docs | is set to a truthy value, :meth:`SMTP.connect` is called with host and port automatically when the object is created; otherwise, :meth:`!SMTP.connect` must be called manually.
The optional arguments *local_hostname*, *timeout* and *source_address* have the same
meaning as they do in the :class:`SMTP` class. *context*,... | is set to a truthy value, :meth:`SMTP.connect` is called with host and port automatically when the object is created; otherwise, :meth:`!SMTP.connect` must be called manually.
The optional arguments *local_hostname*, *timeout* and *source_address* have the same
meaning as they do in the :class:`SMTP` class. *context*,... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
1c7cb368-4530-4eea-9794-6518065e6596 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,321 | supabase-export-v2 | 22bc36f013568e59 | .. method:: SMTP.send_message(msg, from_addr=None, to_addrs=None, \ mail_options=(), rcpt_options=())
This is a convenience method for calling :meth:`sendmail` with the message
represented by an :class:`email.message.Message` object. The arguments have
the same meaning as for :meth:`sendmail`, except that *msg* is a ... | trusted_official_docs | CPython Docs | .. method:: SMTP.send_message(msg, from_addr=None, to_addrs=None, \ mail_options=(), rcpt_options=())
This is a convenience method for calling :meth:`sendmail` with the message
represented by an :class:`email.message.Message` object. The arguments have
the same meaning as for :meth:`sendmail`, except that *msg* is a ... | .. method:: SMTP.send_message(msg, from_addr=None, to_addrs=None, \ mail_options=(), rcpt_options=())
This is a convenience method for calling :meth:`sendmail` with the message
represented by an :class:`email.message.Message` object. The arguments have
the same meaning as for :meth:`sendmail`, except that *msg* is a ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
25a696c1-26ac-4ea1-93d4-47a9f089480c | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,320 | supabase-export-v2 | f9fdcb74764b4335 | .. versionchanged:: 3.5 ``SMTPUTF8`` support added, and :exc:`SMTPNotSupportedError` may be raised if ``SMTPUTF8`` is specified but the server does not support it.
.. method:: SMTP.send_message(msg, from_addr=None, to_addrs=None, \
mail_options=(), rcpt_options=()) | trusted_official_docs | CPython Docs | .. versionchanged:: 3.5 ``SMTPUTF8`` support added, and :exc:`SMTPNotSupportedError` may be raised if ``SMTPUTF8`` is specified but the server does not support it.
.. method:: SMTP.send_message(msg, from_addr=None, to_addrs=None, \
mail_options=(), rcpt_options=()) | .. versionchanged:: 3.5 ``SMTPUTF8`` support added, and :exc:`SMTPNotSupportedError` may be raised if ``SMTPUTF8`` is specified but the server does not support it.
.. method:: SMTP.send_message(msg, from_addr=None, to_addrs=None, \
mail_options=(), rcpt_options=()) | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
270e9aa4-2748-4a4b-81c2-1b86b4f85a2e | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,344 | supabase-export-v2 | f5e775e2bc13ac94 | and To: headers at the start! lines = [f"From: {from_addr}", f"To: {', '.join(to_addrs)}", ""] while True: try: line = input() except EOFError: break else: lines.append(line)
msg = "\r\n".join(lines)
print("Message length is", len(msg)) | trusted_official_docs | CPython Docs | and To: headers at the start! lines = [f"From: {from_addr}", f"To: {', '.join(to_addrs)}", ""] while True: try: line = input() except EOFError: break else: lines.append(line)
msg = "\r\n".join(lines)
print("Message length is", len(msg)) | and To: headers at the start! lines = [f"From: {from_addr}", f"To: {', '.join(to_addrs)}", ""] while True: try: line = input() except EOFError: break else: lines.append(line)
msg = "\r\n".join(lines)
print("Message length is", len(msg)) | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
2a6d8d9c-bae1-4a29-aefe-b1e86c194152 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,209 | supabase-export-v2 | 8801159c41d663b3 | .. versionchanged:: 3.9 If the *timeout* parameter is set to be zero, it will raise a :class:`ValueError` to prevent the creation of a non-blocking socket
.. versionchanged:: 3.12
The deprecated *keyfile* and *certfile* parameters have been removed. | trusted_official_docs | CPython Docs | .. versionchanged:: 3.9 If the *timeout* parameter is set to be zero, it will raise a :class:`ValueError` to prevent the creation of a non-blocking socket
.. versionchanged:: 3.12
The deprecated *keyfile* and *certfile* parameters have been removed. | .. versionchanged:: 3.9 If the *timeout* parameter is set to be zero, it will raise a :class:`ValueError` to prevent the creation of a non-blocking socket
.. versionchanged:: 3.12
The deprecated *keyfile* and *certfile* parameters have been removed. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
2bd97d8b-60d4-4afb-84a3-1abf5e8c0192 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,322 | supabase-export-v2 | 2786a015ac1a7c84 | :meth:`sendmail` with the message represented by an :class:`email.message.Message` object. The arguments have the same meaning as for :meth:`sendmail`, except that *msg* is a ``Message`` object.
If *from_addr* is ``None`` or *to_addrs* is ``None``, ``send_message`` fills
those arguments with addresses extracted from t... | trusted_official_docs | CPython Docs | :meth:`sendmail` with the message represented by an :class:`email.message.Message` object. The arguments have the same meaning as for :meth:`sendmail`, except that *msg* is a ``Message`` object.
If *from_addr* is ``None`` or *to_addrs* is ``None``, ``send_message`` fills
those arguments with addresses extracted from t... | :meth:`sendmail` with the message represented by an :class:`email.message.Message` object. The arguments have the same meaning as for :meth:`sendmail`, except that *msg* is a ``Message`` object.
If *from_addr* is ``None`` or *to_addrs* is ``None``, ``send_message`` fills
those arguments with addresses extracted from t... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
31f4135c-f910-48ff-8555-44d1b934aa5a | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,198 | supabase-export-v2 | cb39ecb24846062b | .. versionadded:: 3.5 The SMTPUTF8 extension (:rfc:`6531`) is now supported.
.. versionchanged:: 3.9
If the *timeout* parameter is set to be zero, it will raise a
:class:`ValueError` to prevent the creation of a non-blocking socket. | trusted_official_docs | CPython Docs | .. versionadded:: 3.5 The SMTPUTF8 extension (:rfc:`6531`) is now supported.
.. versionchanged:: 3.9
If the *timeout* parameter is set to be zero, it will raise a
:class:`ValueError` to prevent the creation of a non-blocking socket. | .. versionadded:: 3.5 The SMTPUTF8 extension (:rfc:`6531`) is now supported.
.. versionchanged:: 3.9
If the *timeout* parameter is set to be zero, it will raise a
:class:`ValueError` to prevent the creation of a non-blocking socket. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
36c2b394-08fb-4eda-af67-e23635b8f660 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,187 | supabase-export-v2 | d4cd69c77f789043 | and/or to some specific source TCP port. It takes a 2-tuple ``(host, port)``, for the socket to bind to as its source address before connecting.
If omitted (or if *host* or *port* are ``''`` and/or ``0``
respectively) the OS default behavior will be used. | trusted_official_docs | CPython Docs | and/or to some specific source TCP port. It takes a 2-tuple ``(host, port)``, for the socket to bind to as its source address before connecting.
If omitted (or if *host* or *port* are ``''`` and/or ``0``
respectively) the OS default behavior will be used. | and/or to some specific source TCP port. It takes a 2-tuple ``(host, port)``, for the socket to bind to as its source address before connecting.
If omitted (or if *host* or *port* are ``''`` and/or ``0``
respectively) the OS default behavior will be used. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
3a84afee-b68c-4ad1-a6a7-46572a38cde9 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,252 | supabase-export-v2 | ec268eefa4cc764e | it should not be necessary to call this method explicitly. It is used to implement other methods and may be useful for testing private extensions.
If the connection to the server is lost while waiting for the reply,
:exc:`SMTPServerDisconnected` will be raised. | trusted_official_docs | CPython Docs | it should not be necessary to call this method explicitly. It is used to implement other methods and may be useful for testing private extensions.
If the connection to the server is lost while waiting for the reply,
:exc:`SMTPServerDisconnected` will be raised. | it should not be necessary to call this method explicitly. It is used to implement other methods and may be useful for testing private extensions.
If the connection to the server is lost while waiting for the reply,
:exc:`SMTPServerDisconnected` will be raised. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
3f872399-9c01-45f6-9b59-f4b0012617b0 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,308 | supabase-export-v2 | 0714044d7dbd2090 | is encoded to bytes using the ascii codec, and lone ``\r`` and ``\n`` characters are converted to ``\r\n`` characters. A byte string is not modified.
If there has been no previous ``EHLO`` or ``HELO`` command this session, this
method tries ESMTP ``EHLO`` first. If the server does ESMTP, message size and
each of the ... | trusted_official_docs | CPython Docs | is encoded to bytes using the ascii codec, and lone ``\r`` and ``\n`` characters are converted to ``\r\n`` characters. A byte string is not modified.
If there has been no previous ``EHLO`` or ``HELO`` command this session, this
method tries ESMTP ``EHLO`` first. If the server does ESMTP, message size and
each of the ... | is encoded to bytes using the ascii codec, and lone ``\r`` and ``\n`` characters are converted to ``\r\n`` characters. A byte string is not modified.
If there has been no previous ``EHLO`` or ``HELO`` command this session, this
method tries ESMTP ``EHLO`` first. If the server does ESMTP, message size and
each of the ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
4256fd72-c7c6-4dac-a316-9b72b11ffd18 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,310 | supabase-export-v2 | 53069df5a7a31494 | for each recipient that was refused. Each entry contains a tuple of the SMTP error code and the accompanying error message sent by the server.
If ``SMTPUTF8`` is included in *mail_options*, and the server supports it,
*from_addr* and *to_addrs* may contain non-ASCII characters. | trusted_official_docs | CPython Docs | for each recipient that was refused. Each entry contains a tuple of the SMTP error code and the accompanying error message sent by the server.
If ``SMTPUTF8`` is included in *mail_options*, and the server supports it,
*from_addr* and *to_addrs* may contain non-ASCII characters. | for each recipient that was refused. Each entry contains a tuple of the SMTP error code and the accompanying error message sent by the server.
If ``SMTPUTF8`` is included in *mail_options*, and the server supports it,
*from_addr* and *to_addrs* may contain non-ASCII characters. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
548220d7-ca11-4fee-8402-2e31dcbaeef2 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,212 | supabase-export-v2 | e04da6942a604c77 | meaning as they do in the :class:`SMTP` class. To specify a Unix socket, you must use an absolute path for *host*, starting with a '/'.
Authentication is supported, using the regular SMTP mechanism. When using a
Unix socket, LMTP generally don't support or require any authentication, but
your mileage might vary. | trusted_official_docs | CPython Docs | meaning as they do in the :class:`SMTP` class. To specify a Unix socket, you must use an absolute path for *host*, starting with a '/'.
Authentication is supported, using the regular SMTP mechanism. When using a
Unix socket, LMTP generally don't support or require any authentication, but
your mileage might vary. | meaning as they do in the :class:`SMTP` class. To specify a Unix socket, you must use an absolute path for *host*, starting with a '/'.
Authentication is supported, using the regular SMTP mechanism. When using a
Unix socket, LMTP generally don't support or require any authentication, but
your mileage might vary. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
558ba9ef-617f-43be-9777-78b6b3c1e1e0 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,246 | supabase-export-v2 | 8d5f1bbf71a55c4e | .. method:: SMTP.set_debuglevel(level)
Set the debug output level. A value of 1 or ``True`` for *level* results in
debug messages for connection and for all messages sent to and received from
the server. A value of 2 for *level* results in these messages being
timestamped. | trusted_official_docs | CPython Docs | .. method:: SMTP.set_debuglevel(level)
Set the debug output level. A value of 1 or ``True`` for *level* results in
debug messages for connection and for all messages sent to and received from
the server. A value of 2 for *level* results in these messages being
timestamped. | .. method:: SMTP.set_debuglevel(level)
Set the debug output level. A value of 1 or ``True`` for *level* results in
debug messages for connection and for all messages sent to and received from
the server. A value of 2 for *level* results in these messages being
timestamped. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
55d077fb-0734-4a55-bd58-1b396cf9bb8e | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,323 | supabase-export-v2 | 043749a467c3d6d1 | than one set of :mailheader:`Resent-*` headers, a :exc:`ValueError` is raised, since there is no way to unambiguously detect the most recent set of :mailheader:`Resent-` headers.
``send_message`` serializes *msg* using
:class:`~email.generator.BytesGenerator` with ``\r\n`` as the *linesep*, and
calls :meth:`sendmail`... | trusted_official_docs | CPython Docs | than one set of :mailheader:`Resent-*` headers, a :exc:`ValueError` is raised, since there is no way to unambiguously detect the most recent set of :mailheader:`Resent-` headers.
``send_message`` serializes *msg* using
:class:`~email.generator.BytesGenerator` with ``\r\n`` as the *linesep*, and
calls :meth:`sendmail`... | than one set of :mailheader:`Resent-*` headers, a :exc:`ValueError` is raised, since there is no way to unambiguously detect the most recent set of :mailheader:`Resent-` headers.
``send_message`` serializes *msg* using
:class:`~email.generator.BytesGenerator` with ``\r\n`` as the *linesep*, and
calls :meth:`sendmail`... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
56e8c697-ec46-46dd-89da-7368648e7a6a | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,309 | supabase-export-v2 | 8191e84ef0a69d8a | passed to it (if the option is in the feature set the server advertises). If ``EHLO`` fails, ``HELO`` will be tried and ESMTP options suppressed.
This method will return normally if the mail is accepted for at least one
recipient. Otherwise it will raise an exception. That is, if this method does
not raise an excepti... | trusted_official_docs | CPython Docs | passed to it (if the option is in the feature set the server advertises). If ``EHLO`` fails, ``HELO`` will be tried and ESMTP options suppressed.
This method will return normally if the mail is accepted for at least one
recipient. Otherwise it will raise an exception. That is, if this method does
not raise an excepti... | passed to it (if the option is in the feature set the server advertises). If ``EHLO`` fails, ``HELO`` will be tried and ESMTP options suppressed.
This method will return normally if the mail is accepted for at least one
recipient. Otherwise it will raise an exception. That is, if this method does
not raise an excepti... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
59ffb669-00e0-47d4-83d8-c3611b3341b2 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,274 | supabase-export-v2 | 6efd14367de73630 | command this session, this method tries ESMTP ``EHLO`` first. This method will return normally if the authentication was successful, or may raise the following exceptions:
:exc:`SMTPHeloError`
The server didn't reply properly to the ``HELO`` greeting. | trusted_official_docs | CPython Docs | command this session, this method tries ESMTP ``EHLO`` first. This method will return normally if the authentication was successful, or may raise the following exceptions:
:exc:`SMTPHeloError`
The server didn't reply properly to the ``HELO`` greeting. | command this session, this method tries ESMTP ``EHLO`` first. This method will return normally if the authentication was successful, or may raise the following exceptions:
:exc:`SMTPHeloError`
The server didn't reply properly to the ``HELO`` greeting. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
65300c0d-1ccc-4475-9e74-a35e6c9aae0c | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,242 | supabase-export-v2 | b07f2d25e370f338 | :rfc:`821` - Simple Mail Transfer Protocol Protocol definition for SMTP. This document covers the model, operating procedure, and protocol details for SMTP.
:rfc:`1869` - SMTP Service Extensions
Definition of the ESMTP extensions for SMTP. This describes a framework for
extending SMTP with new commands, supporting dy... | trusted_official_docs | CPython Docs | :rfc:`821` - Simple Mail Transfer Protocol Protocol definition for SMTP. This document covers the model, operating procedure, and protocol details for SMTP.
:rfc:`1869` - SMTP Service Extensions
Definition of the ESMTP extensions for SMTP. This describes a framework for
extending SMTP with new commands, supporting dy... | :rfc:`821` - Simple Mail Transfer Protocol Protocol definition for SMTP. This document covers the model, operating procedure, and protocol details for SMTP.
:rfc:`1869` - SMTP Service Extensions
Definition of the ESMTP extensions for SMTP. This describes a framework for
extending SMTP with new commands, supporting dy... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
6dc6446b-a636-4c2e-a939-bf5338825ab7 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,328 | supabase-export-v2 | 5752a7b24bfb3f02 | Terminate the SMTP session and close the connection. Return the result of the SMTP ``QUIT`` command.
Low-level methods corresponding to the standard SMTP/ESMTP commands ``HELP``,
``RSET``, ``NOOP``, ``MAIL``, ``RCPT``, and ``DATA`` are also supported. Normally these do not need to be called directly, so they are not do... | trusted_official_docs | CPython Docs | Terminate the SMTP session and close the connection. Return the result of the SMTP ``QUIT`` command.
Low-level methods corresponding to the standard SMTP/ESMTP commands ``HELP``,
``RSET``, ``NOOP``, ``MAIL``, ``RCPT``, and ``DATA`` are also supported. Normally these do not need to be called directly, so they are not do... | Terminate the SMTP session and close the connection. Return the result of the SMTP ``QUIT`` command.
Low-level methods corresponding to the standard SMTP/ESMTP commands ``HELP``,
``RSET``, ``NOOP``, ``MAIL``, ``RCPT``, and ``DATA`` are also supported. Normally these do not need to be called directly, so they are not do... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
6dde07b5-496a-46f9-8c5e-55f3724aabdd | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,279 | supabase-export-v2 | 92956a83f4c620e8 | turn if they are advertised as supported by the server. See :meth:`auth` for a list of supported authentication methods. *initial_response_ok* is passed through to :meth:`auth`.
Optional keyword argument *initial_response_ok* specifies whether, for
authentication methods that support it, an "initial response" as speci... | trusted_official_docs | CPython Docs | turn if they are advertised as supported by the server. See :meth:`auth` for a list of supported authentication methods. *initial_response_ok* is passed through to :meth:`auth`.
Optional keyword argument *initial_response_ok* specifies whether, for
authentication methods that support it, an "initial response" as speci... | turn if they are advertised as supported by the server. See :meth:`auth` for a list of supported authentication methods. *initial_response_ok* is passed through to :meth:`auth`.
Optional keyword argument *initial_response_ok* specifies whether, for
authentication methods that support it, an "initial response" as speci... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
6fd88123-0eda-4beb-a0ea-b24c3eed0b59 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,181 | supabase-export-v2 | da03f6f22187aff8 | --------------
The :mod:`!smtplib` module defines an SMTP client session object that can be used
to send mail to any internet machine with an SMTP or ESMTP listener daemon. For
details of SMTP and ESMTP operation, consult :rfc:`821` (Simple Mail Transfer
Protocol) and :rfc:`1869` (SMTP Service Extensions). | trusted_official_docs | CPython Docs | --------------
The :mod:`!smtplib` module defines an SMTP client session object that can be used
to send mail to any internet machine with an SMTP or ESMTP listener daemon. For
details of SMTP and ESMTP operation, consult :rfc:`821` (Simple Mail Transfer
Protocol) and :rfc:`1869` (SMTP Service Extensions). | --------------
The :mod:`!smtplib` module defines an SMTP client session object that can be used
to send mail to any internet machine with an SMTP or ESMTP listener daemon. For
details of SMTP and ESMTP operation, consult :rfc:`821` (Simple Mail Transfer
Protocol) and :rfc:`1869` (SMTP Service Extensions). | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
70384e7a-4f3f-46e7-8168-508c619f51e9 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,278 | supabase-export-v2 | 811ddc154df48813 | :exc:`SMTPException` No suitable authentication method was found.
Each of the authentication methods supported by :mod:`!smtplib` are tried in
turn if they are advertised as supported by the server. See :meth:`auth`
for a list of supported authentication methods. *initial_response_ok* is
passed through to :meth:`aut... | trusted_official_docs | CPython Docs | :exc:`SMTPException` No suitable authentication method was found.
Each of the authentication methods supported by :mod:`!smtplib` are tried in
turn if they are advertised as supported by the server. See :meth:`auth`
for a list of supported authentication methods. *initial_response_ok* is
passed through to :meth:`aut... | :exc:`SMTPException` No suitable authentication method was found.
Each of the authentication methods supported by :mod:`!smtplib` are tried in
turn if they are advertised as supported by the server. See :meth:`auth`
for a list of supported authentication methods. *initial_response_ok* is
passed through to :meth:`aut... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
766dbe67-3265-4451-805f-70ef6c027a95 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,192 | supabase-export-v2 | 38550688b1867fd4 | .. audit-event:: smtplib.send self,data smtplib.SMTP
All commands will raise an :ref:`auditing event <auditing>`
``smtplib.SMTP.send`` with arguments ``self`` and ``data``,
where ``data`` is the bytes about to be sent to the remote host. | trusted_official_docs | CPython Docs | .. audit-event:: smtplib.send self,data smtplib.SMTP
All commands will raise an :ref:`auditing event <auditing>`
``smtplib.SMTP.send`` with arguments ``self`` and ``data``,
where ``data`` is the bytes about to be sent to the remote host. | .. audit-event:: smtplib.send self,data smtplib.SMTP
All commands will raise an :ref:`auditing event <auditing>`
``smtplib.SMTP.send`` with arguments ``self`` and ``data``,
where ``data`` is the bytes about to be sent to the remote host. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
79c85d26-8c42-4741-9307-63dffc05677d | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,200 | supabase-export-v2 | b5b791d662e80c44 | .. class:: SMTP_SSL(host='', port=0, local_hostname=None, * [, timeout], \ context=None, source_address=None)
An :class:`SMTP_SSL` instance behaves exactly the same as instances of
:class:`SMTP`. :class:`SMTP_SSL` should be used for situations where SSL is
required from the beginning of the connection and using :meth... | trusted_official_docs | CPython Docs | .. class:: SMTP_SSL(host='', port=0, local_hostname=None, * [, timeout], \ context=None, source_address=None)
An :class:`SMTP_SSL` instance behaves exactly the same as instances of
:class:`SMTP`. :class:`SMTP_SSL` should be used for situations where SSL is
required from the beginning of the connection and using :meth... | .. class:: SMTP_SSL(host='', port=0, local_hostname=None, * [, timeout], \ context=None, source_address=None)
An :class:`SMTP_SSL` instance behaves exactly the same as instances of
:class:`SMTP`. :class:`SMTP_SSL` should be used for situations where SSL is
required from the beginning of the connection and using :meth... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
7e08c3b6-6077-4086-862c-2e98461ac9a1 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,251 | supabase-export-v2 | 5af624d99a6e973b | This returns a 2-tuple composed of a numeric response code and the actual response line (multiline responses are joined into one long line.)
In normal operation it should not be necessary to call this method explicitly. It is used to implement other methods and may be useful for testing private
extensions. | trusted_official_docs | CPython Docs | This returns a 2-tuple composed of a numeric response code and the actual response line (multiline responses are joined into one long line.)
In normal operation it should not be necessary to call this method explicitly. It is used to implement other methods and may be useful for testing private
extensions. | This returns a 2-tuple composed of a numeric response code and the actual response line (multiline responses are joined into one long line.)
In normal operation it should not be necessary to call this method explicitly. It is used to implement other methods and may be useful for testing private
extensions. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
82ea82c7-a4bb-46b3-aa44-ef1a5d7e85cc | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,258 | supabase-export-v2 | 752e9fb5fadcc6bd | .. method:: SMTP.helo(name='')
Identify yourself to the SMTP server using ``HELO``. The hostname argument
defaults to the fully qualified domain name of the local host. The message returned by the server is stored as the :attr:`helo_resp` attribute
of the object. | trusted_official_docs | CPython Docs | .. method:: SMTP.helo(name='')
Identify yourself to the SMTP server using ``HELO``. The hostname argument
defaults to the fully qualified domain name of the local host. The message returned by the server is stored as the :attr:`helo_resp` attribute
of the object. | .. method:: SMTP.helo(name='')
Identify yourself to the SMTP server using ``HELO``. The hostname argument
defaults to the fully qualified domain name of the local host. The message returned by the server is stored as the :attr:`helo_resp` attribute
of the object. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
87c3b2a0-27e9-4f3d-a773-9706dd89273f | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,265 | supabase-export-v2 | fa4ce6735f724479 | This method calls :meth:`ehlo` and/or :meth:`helo` if there has been no previous ``EHLO`` or ``HELO`` command this session. It tries ESMTP ``EHLO`` first.
:exc:`SMTPHeloError`
The server didn't reply properly to the ``HELO`` greeting. | trusted_official_docs | CPython Docs | This method calls :meth:`ehlo` and/or :meth:`helo` if there has been no previous ``EHLO`` or ``HELO`` command this session. It tries ESMTP ``EHLO`` first.
:exc:`SMTPHeloError`
The server didn't reply properly to the ``HELO`` greeting. | This method calls :meth:`ehlo` and/or :meth:`helo` if there has been no previous ``EHLO`` or ``HELO`` command this session. It tries ESMTP ``EHLO`` first.
:exc:`SMTPHeloError`
The server didn't reply properly to the ``HELO`` greeting. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
8ec0fa5d-b1da-4e01-aad6-3ace7c0e5591 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,259 | supabase-export-v2 | 3d1286a8b086e30e | to the fully qualified domain name of the local host. The message returned by the server is stored as the :attr:`helo_resp` attribute of the object.
In normal operation it should not be necessary to call this method explicitly. It will be implicitly called by the :meth:`sendmail` when necessary. | trusted_official_docs | CPython Docs | to the fully qualified domain name of the local host. The message returned by the server is stored as the :attr:`helo_resp` attribute of the object.
In normal operation it should not be necessary to call this method explicitly. It will be implicitly called by the :meth:`sendmail` when necessary. | to the fully qualified domain name of the local host. The message returned by the server is stored as the :attr:`helo_resp` attribute of the object.
In normal operation it should not be necessary to call this method explicitly. It will be implicitly called by the :meth:`sendmail` when necessary. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
914243ca-23f7-4880-8697-bc902194d19b | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,190 | supabase-export-v2 | d94689bd0c15d11d | The :class:`SMTP` class supports the :keyword:`with` statement. When used like this, the SMTP ``QUIT`` command is issued automatically when the :keyword:`!with` statement exits. E.g.::
>>> from smtplib import SMTP
>>> with SMTP("domain.org") as smtp:
... smtp.noop()
... (250, b'Ok')
>>> | trusted_official_docs | CPython Docs | The :class:`SMTP` class supports the :keyword:`with` statement. When used like this, the SMTP ``QUIT`` command is issued automatically when the :keyword:`!with` statement exits. E.g.::
>>> from smtplib import SMTP
>>> with SMTP("domain.org") as smtp:
... smtp.noop()
... (250, b'Ok')
>>> | The :class:`SMTP` class supports the :keyword:`with` statement. When used like this, the SMTP ``QUIT`` command is issued automatically when the :keyword:`!with` statement exits. E.g.::
>>> from smtplib import SMTP
>>> with SMTP("domain.org") as smtp:
... smtp.noop()
... (250, b'Ok')
>>> | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
91d1cd2b-e410-455c-86d3-c6205cc9fd6f | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,289 | supabase-export-v2 | 9a8c7a330314d81c | are named ``SMTP.auth_cram_md5``, ``SMTP.auth_plain``, and ``SMTP.auth_login`` respectively. They all require that the ``user`` and ``password`` properties of the ``SMTP`` instance are set to appropriate values.
User code does not normally need to call ``auth`` directly, but can instead
call the :meth:`login` method, ... | trusted_official_docs | CPython Docs | are named ``SMTP.auth_cram_md5``, ``SMTP.auth_plain``, and ``SMTP.auth_login`` respectively. They all require that the ``user`` and ``password`` properties of the ``SMTP`` instance are set to appropriate values.
User code does not normally need to call ``auth`` directly, but can instead
call the :meth:`login` method, ... | are named ``SMTP.auth_cram_md5``, ``SMTP.auth_plain``, and ``SMTP.auth_login`` respectively. They all require that the ``user`` and ``password`` properties of the ``SMTP`` instance are set to appropriate values.
User code does not normally need to call ``auth`` directly, but can instead
call the :meth:`login` method, ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
92df9442-8898-4c38-9db9-88d9c544de0d | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,284 | supabase-export-v2 | 5fdc392c6874f11f | which authentication mechanism is to be used as argument to the ``AUTH`` command; the valid values are those listed in the ``auth`` element of :attr:`esmtp_features`.
*authobject* must be a callable object taking an optional single argument:: | trusted_official_docs | CPython Docs | which authentication mechanism is to be used as argument to the ``AUTH`` command; the valid values are those listed in the ``auth`` element of :attr:`esmtp_features`.
*authobject* must be a callable object taking an optional single argument:: | which authentication mechanism is to be used as argument to the ``AUTH`` command; the valid values are those listed in the ``auth`` element of :attr:`esmtp_features`.
*authobject* must be a callable object taking an optional single argument:: | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
a130927b-e2db-407f-9dc2-514c0d0d7ba1 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,339 | supabase-export-v2 | 04152c2d9e2890cc | SMTP Example ------------
This example prompts the user for addresses needed in the message envelope ('To'
and 'From' addresses), and the message to be delivered. Note that the headers
to be included with the message must be included in the message as entered; this
example doesn't do any processing of the :rfc:`822` he... | trusted_official_docs | CPython Docs | SMTP Example ------------
This example prompts the user for addresses needed in the message envelope ('To'
and 'From' addresses), and the message to be delivered. Note that the headers
to be included with the message must be included in the message as entered; this
example doesn't do any processing of the :rfc:`822` he... | SMTP Example ------------
This example prompts the user for addresses needed in the message envelope ('To'
and 'From' addresses), and the message to be delivered. Note that the headers
to be included with the message must be included in the message as entered; this
example doesn't do any processing of the :rfc:`822` he... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
a35f0ff4-99af-426f-902d-1a78cf0297b4 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,296 | supabase-export-v2 | 159c59ed4c64e072 | If there has been no previous ``EHLO`` or ``HELO`` command this session, this method tries ESMTP ``EHLO`` first.
.. versionchanged:: 3.12
The deprecated *keyfile* and *certfile* parameters have been removed. | trusted_official_docs | CPython Docs | If there has been no previous ``EHLO`` or ``HELO`` command this session, this method tries ESMTP ``EHLO`` first.
.. versionchanged:: 3.12
The deprecated *keyfile* and *certfile* parameters have been removed. | If there has been no previous ``EHLO`` or ``HELO`` command this session, this method tries ESMTP ``EHLO`` first.
.. versionchanged:: 3.12
The deprecated *keyfile* and *certfile* parameters have been removed. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
a66d55c4-d649-400d-a94a-3c48c26dbd50 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,255 | supabase-export-v2 | 69be321a43175aeb | constructor if a host is specified during instantiation. Returns a 2-tuple of the response code and message sent by the server in its connection response.
If port is not changed from its default value of 0, the value of the :attr:`default_port`
attribute is used. | trusted_official_docs | CPython Docs | constructor if a host is specified during instantiation. Returns a 2-tuple of the response code and message sent by the server in its connection response.
If port is not changed from its default value of 0, the value of the :attr:`default_port`
attribute is used. | constructor if a host is specified during instantiation. Returns a 2-tuple of the response code and message sent by the server in its connection response.
If port is not changed from its default value of 0, the value of the :attr:`default_port`
attribute is used. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
a8c0bc7f-9ad3-44ad-ac2f-02346fd5fbc0 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,185 | supabase-export-v2 | 0fb9a05f3cba5844 | An :class:`SMTP` instance encapsulates an SMTP connection. It has methods that support a full repertoire of SMTP and ESMTP operations.
If the host parameter is set to a truthy value, :meth:`SMTP.connect` is called with
host and port automatically when the object is created; otherwise, :meth:`!connect` must
be called ... | trusted_official_docs | CPython Docs | An :class:`SMTP` instance encapsulates an SMTP connection. It has methods that support a full repertoire of SMTP and ESMTP operations.
If the host parameter is set to a truthy value, :meth:`SMTP.connect` is called with
host and port automatically when the object is created; otherwise, :meth:`!connect` must
be called ... | An :class:`SMTP` instance encapsulates an SMTP connection. It has methods that support a full repertoire of SMTP and ESMTP operations.
If the host parameter is set to a truthy value, :meth:`SMTP.connect` is called with
host and port automatically when the object is created; otherwise, :meth:`!connect` must
be called ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
aa9b8373-5192-4b9f-995e-a073ffc4db6f | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,262 | supabase-export-v2 | 1cebec69808851fc | server supports ESMTP, and :attr:`esmtp_features` will be a dictionary containing the names of the SMTP service extensions this server supports, and their parameters (if any).
Unless you wish to use :meth:`has_extn` before sending mail, it should not be
necessary to call this method explicitly. It will be implicitly c... | trusted_official_docs | CPython Docs | server supports ESMTP, and :attr:`esmtp_features` will be a dictionary containing the names of the SMTP service extensions this server supports, and their parameters (if any).
Unless you wish to use :meth:`has_extn` before sending mail, it should not be
necessary to call this method explicitly. It will be implicitly c... | server supports ESMTP, and :attr:`esmtp_features` will be a dictionary containing the names of the SMTP service extensions this server supports, and their parameters (if any).
Unless you wish to use :meth:`has_extn` before sending mail, it should not be
necessary to call this method explicitly. It will be implicitly c... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
b3a795a1-a2ae-438b-b466-dc1be77814be | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,261 | supabase-export-v2 | 2a6cabef079560cf | .. method:: SMTP.ehlo(name='')
Identify yourself to an ESMTP server using ``EHLO``. The hostname argument
defaults to the fully qualified domain name of the local host. Examine the
response for ESMTP option and store them for use by :meth:`has_extn`. Also sets several informational attributes: the message returned by... | trusted_official_docs | CPython Docs | .. method:: SMTP.ehlo(name='')
Identify yourself to an ESMTP server using ``EHLO``. The hostname argument
defaults to the fully qualified domain name of the local host. Examine the
response for ESMTP option and store them for use by :meth:`has_extn`. Also sets several informational attributes: the message returned by... | .. method:: SMTP.ehlo(name='')
Identify yourself to an ESMTP server using ``EHLO``. The hostname argument
defaults to the fully qualified domain name of the local host. Examine the
response for ESMTP option and store them for use by :meth:`has_extn`. Also sets several informational attributes: the message returned by... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
b63cd551-1520-461d-acbc-153017440860 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,316 | supabase-export-v2 | f9ae946a901c9ca8 | :exc:`SMTPDataError` The server replied with an unexpected error code (other than a refusal of a recipient).
:exc:`SMTPNotSupportedError`
``SMTPUTF8`` was given in the *mail_options* but is not supported by the
server. | trusted_official_docs | CPython Docs | :exc:`SMTPDataError` The server replied with an unexpected error code (other than a refusal of a recipient).
:exc:`SMTPNotSupportedError`
``SMTPUTF8`` was given in the *mail_options* but is not supported by the
server. | :exc:`SMTPDataError` The server replied with an unexpected error code (other than a refusal of a recipient).
:exc:`SMTPNotSupportedError`
``SMTPUTF8`` was given in the *mail_options* but is not supported by the
server. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c5e45572-088f-451d-80d9-2e55cc88d9db | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,213 | supabase-export-v2 | 37c22edbdb4f20dd | is supported, using the regular SMTP mechanism. When using a Unix socket, LMTP generally don't support or require any authentication, but your mileage might vary.
.. versionchanged:: 3.9
The optional *timeout* parameter was added. | trusted_official_docs | CPython Docs | is supported, using the regular SMTP mechanism. When using a Unix socket, LMTP generally don't support or require any authentication, but your mileage might vary.
.. versionchanged:: 3.9
The optional *timeout* parameter was added. | is supported, using the regular SMTP mechanism. When using a Unix socket, LMTP generally don't support or require any authentication, but your mileage might vary.
.. versionchanged:: 3.9
The optional *timeout* parameter was added. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c728c4e5-1beb-4ded-a6ef-7fb4ec973538 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,295 | supabase-export-v2 | eacec4e1bbdde5b2 | is an :class:`ssl.SSLContext` object; This is an alternative to using a keyfile and a certfile and if specified both *keyfile* and *certfile* should be ``None``.
If there has been no previous ``EHLO`` or ``HELO`` command this session,
this method tries ESMTP ``EHLO`` first. | trusted_official_docs | CPython Docs | is an :class:`ssl.SSLContext` object; This is an alternative to using a keyfile and a certfile and if specified both *keyfile* and *certfile* should be ``None``.
If there has been no previous ``EHLO`` or ``HELO`` command this session,
this method tries ESMTP ``EHLO`` first. | is an :class:`ssl.SSLContext` object; This is an alternative to using a keyfile and a certfile and if specified both *keyfile* and *certfile* should be ``None``.
If there has been no previous ``EHLO`` or ``HELO`` command this session,
this method tries ESMTP ``EHLO`` first. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c87783c2-7831-4d3c-ad68-2eb0dab7bed5 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,304 | supabase-export-v2 | 8a3f657564d75cd3 | .. method:: SMTP.sendmail(from_addr, to_addrs, msg, mail_options=(), rcpt_options=())
Send mail. The required arguments are an :rfc:`822` from-address string, a list
of :rfc:`822` to-address strings (a bare string will be treated as a list with 1
address), and a message string. The caller may pass a list of ESMTP opt... | trusted_official_docs | CPython Docs | .. method:: SMTP.sendmail(from_addr, to_addrs, msg, mail_options=(), rcpt_options=())
Send mail. The required arguments are an :rfc:`822` from-address string, a list
of :rfc:`822` to-address strings (a bare string will be treated as a list with 1
address), and a message string. The caller may pass a list of ESMTP opt... | .. method:: SMTP.sendmail(from_addr, to_addrs, msg, mail_options=(), rcpt_options=())
Send mail. The required arguments are an :rfc:`822` from-address string, a list
of :rfc:`822` to-address strings (a bare string will be treated as a list with 1
address), and a message string. The caller may pass a list of ESMTP opt... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
cc0335c3-d5d0-4d4f-a219-b238b57a1b98 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,208 | supabase-export-v2 | fa7af944da121ad5 | .. versionchanged:: 3.4 The class now supports hostname check with :attr:`ssl.SSLContext.check_hostname` and *Server Name Indication* (see :const:`ssl.HAS_SNI`).
.. versionchanged:: 3.9
If the *timeout* parameter is set to be zero, it will raise a
:class:`ValueError` to prevent the creation of a non-blocking socket | trusted_official_docs | CPython Docs | .. versionchanged:: 3.4 The class now supports hostname check with :attr:`ssl.SSLContext.check_hostname` and *Server Name Indication* (see :const:`ssl.HAS_SNI`).
.. versionchanged:: 3.9
If the *timeout* parameter is set to be zero, it will raise a
:class:`ValueError` to prevent the creation of a non-blocking socket | .. versionchanged:: 3.4 The class now supports hostname check with :attr:`ssl.SSLContext.check_hostname` and *Server Name Indication* (see :const:`ssl.HAS_SNI`).
.. versionchanged:: 3.9
If the *timeout* parameter is set to be zero, it will raise a
:class:`ValueError` to prevent the creation of a non-blocking socket | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ced44072-73fb-42c4-9bc6-05d80b3df34e | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,189 | supabase-export-v2 | 90821842535707aa | For normal use, you should only require the initialization/connect, :meth:`sendmail`, and :meth:`SMTP.quit` methods. An example is included below.
The :class:`SMTP` class supports the :keyword:`with` statement. When used
like this, the SMTP ``QUIT`` command is issued automatically when the
:keyword:`!with` statement ... | trusted_official_docs | CPython Docs | For normal use, you should only require the initialization/connect, :meth:`sendmail`, and :meth:`SMTP.quit` methods. An example is included below.
The :class:`SMTP` class supports the :keyword:`with` statement. When used
like this, the SMTP ``QUIT`` command is issued automatically when the
:keyword:`!with` statement ... | For normal use, you should only require the initialization/connect, :meth:`sendmail`, and :meth:`SMTP.quit` methods. An example is included below.
The :class:`SMTP` class supports the :keyword:`with` statement. When used
like this, the SMTP ``QUIT`` command is issued automatically when the
:keyword:`!with` statement ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
d04df346-fae5-4ad9-9112-1705e1157e28 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,343 | supabase-export-v2 | 25f710bbe1a955f0 | from_addr = prompt("From: ") to_addrs = prompt("To: ").split() print("Enter message, end with ^D (Unix) or ^Z (Windows):")
# Add the From: and To: headers at the start! lines = [f"From: {from_addr}", f"To: {', '.join(to_addrs)}", ""]
while True:
try:
line = input()
except EOFError:
break
else:
lines.append(line) | trusted_official_docs | CPython Docs | from_addr = prompt("From: ") to_addrs = prompt("To: ").split() print("Enter message, end with ^D (Unix) or ^Z (Windows):")
# Add the From: and To: headers at the start! lines = [f"From: {from_addr}", f"To: {', '.join(to_addrs)}", ""]
while True:
try:
line = input()
except EOFError:
break
else:
lines.append(line) | from_addr = prompt("From: ") to_addrs = prompt("To: ").split() print("Enter message, end with ^D (Unix) or ^Z (Windows):")
# Add the From: and To: headers at the start! lines = [f"From: {from_addr}", f"To: {', '.join(to_addrs)}", ""]
while True:
try:
line = input()
except EOFError:
break
else:
lines.append(line) | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
d158b8c7-8545-44ff-8e30-b5b520cddb64 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,199 | supabase-export-v2 | 0ae76a063a7f95ff | .. versionchanged:: 3.9 If the *timeout* parameter is set to be zero, it will raise a :class:`ValueError` to prevent the creation of a non-blocking socket.
.. class:: SMTP_SSL(host='', port=0, local_hostname=None, * [, timeout], \
context=None, source_address=None) | trusted_official_docs | CPython Docs | .. versionchanged:: 3.9 If the *timeout* parameter is set to be zero, it will raise a :class:`ValueError` to prevent the creation of a non-blocking socket.
.. class:: SMTP_SSL(host='', port=0, local_hostname=None, * [, timeout], \
context=None, source_address=None) | .. versionchanged:: 3.9 If the *timeout* parameter is set to be zero, it will raise a :class:`ValueError` to prevent the creation of a non-blocking socket.
.. class:: SMTP_SSL(host='', port=0, local_hostname=None, * [, timeout], \
context=None, source_address=None) | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
d231b716-1d29-4ba4-97ad-81a257414114 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,287 | supabase-export-v2 | 7864bd55e51afd42 | it requires a challenge), it should return ``None`` when called with ``challenge=None``. If *initial_response_ok* is false, then ``authobject()`` will not be called first with ``None``.
If the initial response check returns ``None``, or if *initial_response_ok* is
false, ``authobject()`` will be called to process the ... | trusted_official_docs | CPython Docs | it requires a challenge), it should return ``None`` when called with ``challenge=None``. If *initial_response_ok* is false, then ``authobject()`` will not be called first with ``None``.
If the initial response check returns ``None``, or if *initial_response_ok* is
false, ``authobject()`` will be called to process the ... | it requires a challenge), it should return ``None`` when called with ``challenge=None``. If *initial_response_ok* is false, then ``authobject()`` will not be called first with ``None``.
If the initial response check returns ``None``, or if *initial_response_ok* is
false, ``authobject()`` will be called to process the ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
d466d921-a08a-4682-948d-f97ed849489f | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,186 | supabase-export-v2 | 19c00ca1a151b731 | is set to a truthy value, :meth:`SMTP.connect` is called with host and port automatically when the object is created; otherwise, :meth:`!connect` must be called manually.
If specified, *local_hostname* is used as the FQDN of the local host in the HELO/EHLO
command. Otherwise, the local hostname is found using
:func:`... | trusted_official_docs | CPython Docs | is set to a truthy value, :meth:`SMTP.connect` is called with host and port automatically when the object is created; otherwise, :meth:`!connect` must be called manually.
If specified, *local_hostname* is used as the FQDN of the local host in the HELO/EHLO
command. Otherwise, the local hostname is found using
:func:`... | is set to a truthy value, :meth:`SMTP.connect` is called with host and port automatically when the object is created; otherwise, :meth:`!connect` must be called manually.
If specified, *local_hostname* is used as the FQDN of the local host in the HELO/EHLO
command. Otherwise, the local hostname is found using
:func:`... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
d4b4e728-dfdb-4355-a053-c97fc2b202f3 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,307 | supabase-export-v2 | 92846987f15417ba | and *to_addrs* parameters are used to construct the message envelope used by the transport agents. ``sendmail`` does not modify the message headers in any way.
*msg* may be a string containing characters in the ASCII range, or a byte
string. A string is encoded to bytes using the ascii codec, and lone ``\r``
and ``\n... | trusted_official_docs | CPython Docs | and *to_addrs* parameters are used to construct the message envelope used by the transport agents. ``sendmail`` does not modify the message headers in any way.
*msg* may be a string containing characters in the ASCII range, or a byte
string. A string is encoded to bytes using the ascii codec, and lone ``\r``
and ``\n... | and *to_addrs* parameters are used to construct the message envelope used by the transport agents. ``sendmail`` does not modify the message headers in any way.
*msg* may be a string containing characters in the ASCII range, or a byte
string. A string is encoded to bytes using the ascii codec, and lone ``\r``
and ``\n... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
dad3ef60-7ca8-4e3e-bc32-6256adb2e5f3 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,293 | supabase-export-v2 | f682d9c1f372590a | Put the SMTP connection in TLS (Transport Layer Security) mode. All SMTP commands that follow will be encrypted. You should then call :meth:`ehlo` again.
If *keyfile* and *certfile* are provided, they are used to create an
:class:`ssl.SSLContext`. | trusted_official_docs | CPython Docs | Put the SMTP connection in TLS (Transport Layer Security) mode. All SMTP commands that follow will be encrypted. You should then call :meth:`ehlo` again.
If *keyfile* and *certfile* are provided, they are used to create an
:class:`ssl.SSLContext`. | Put the SMTP connection in TLS (Transport Layer Security) mode. All SMTP commands that follow will be encrypted. You should then call :meth:`ehlo` again.
If *keyfile* and *certfile* are provided, they are used to create an
:class:`ssl.SSLContext`. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
e212a08f-9ab9-453d-bba3-5afa1b742fae | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,286 | supabase-export-v2 | 1cba4a96044a126b | data = authobject(challenge=None)
If optional keyword argument *initial_response_ok* is true,
``authobject()`` will be called first with no argument. It can return the
:rfc:`4954` "initial response" ASCII ``str`` which will be encoded and sent with
the ``AUTH`` command as below. If the ``authobject()`` does not supp... | trusted_official_docs | CPython Docs | data = authobject(challenge=None)
If optional keyword argument *initial_response_ok* is true,
``authobject()`` will be called first with no argument. It can return the
:rfc:`4954` "initial response" ASCII ``str`` which will be encoded and sent with
the ``AUTH`` command as below. If the ``authobject()`` does not supp... | data = authobject(challenge=None)
If optional keyword argument *initial_response_ok* is true,
``authobject()`` will be called first with no argument. It can return the
:rfc:`4954` "initial response" ASCII ``str`` which will be encoded and sent with
the ``AUTH`` command as below. If the ``authobject()`` does not supp... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
e276d502-af36-47cb-bd5f-74dcf9ec53bf | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,250 | supabase-export-v2 | 259dce05d4fb19c3 | Send a command *cmd* to the server. The optional argument *args* is simply concatenated to the command, separated by a space.
This returns a 2-tuple composed of a numeric response code and the actual
response line (multiline responses are joined into one long line.) | trusted_official_docs | CPython Docs | Send a command *cmd* to the server. The optional argument *args* is simply concatenated to the command, separated by a space.
This returns a 2-tuple composed of a numeric response code and the actual
response line (multiline responses are joined into one long line.) | Send a command *cmd* to the server. The optional argument *args* is simply concatenated to the command, separated by a space.
This returns a 2-tuple composed of a numeric response code and the actual
response line (multiline responses are joined into one long line.) | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
e5dc2d5e-b556-4d68-b2cd-9c28dc22e031 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,302 | supabase-export-v2 | e3c8e2e6348aa19d | .. versionchanged:: 3.4 The method now supports hostname check with :attr:`ssl.SSLContext.check_hostname` and *Server Name Indicator* (see :const:`~ssl.HAS_SNI`).
.. versionchanged:: 3.5
The error raised for lack of STARTTLS support is now the
:exc:`SMTPNotSupportedError` subclass instead of the base
:exc:`SMTPExcep... | trusted_official_docs | CPython Docs | .. versionchanged:: 3.4 The method now supports hostname check with :attr:`ssl.SSLContext.check_hostname` and *Server Name Indicator* (see :const:`~ssl.HAS_SNI`).
.. versionchanged:: 3.5
The error raised for lack of STARTTLS support is now the
:exc:`SMTPNotSupportedError` subclass instead of the base
:exc:`SMTPExcep... | .. versionchanged:: 3.4 The method now supports hostname check with :attr:`ssl.SSLContext.check_hostname` and *Server Name Indicator* (see :const:`~ssl.HAS_SNI`).
.. versionchanged:: 3.5
The error raised for lack of STARTTLS support is now the
:exc:`SMTPNotSupportedError` subclass instead of the base
:exc:`SMTPExcep... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
e5e5444a-6fa7-4dfe-b46c-c05f011b9b85 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,319 | supabase-export-v2 | 418ff9cfc104e4d5 | .. versionchanged:: 3.2 *msg* may be a byte string.
.. versionchanged:: 3.5
``SMTPUTF8`` support added, and :exc:`SMTPNotSupportedError` may be
raised if ``SMTPUTF8`` is specified but the server does not support it. | trusted_official_docs | CPython Docs | .. versionchanged:: 3.2 *msg* may be a byte string.
.. versionchanged:: 3.5
``SMTPUTF8`` support added, and :exc:`SMTPNotSupportedError` may be
raised if ``SMTPUTF8`` is specified but the server does not support it. | .. versionchanged:: 3.2 *msg* may be a byte string.
.. versionchanged:: 3.5
``SMTPUTF8`` support added, and :exc:`SMTPNotSupportedError` may be
raised if ``SMTPUTF8`` is specified but the server does not support it. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
e5fd1bf0-e703-41c4-9da3-77ee59d3178a | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,247 | supabase-export-v2 | 9911c57a5ee0ee37 | for connection and for all messages sent to and received from the server. A value of 2 for *level* results in these messages being timestamped.
.. versionchanged:: 3.5 Added debuglevel 2. | trusted_official_docs | CPython Docs | for connection and for all messages sent to and received from the server. A value of 2 for *level* results in these messages being timestamped.
.. versionchanged:: 3.5 Added debuglevel 2. | for connection and for all messages sent to and received from the server. A value of 2 for *level* results in these messages being timestamped.
.. versionchanged:: 3.5 Added debuglevel 2. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ebd898f8-5f1f-408a-be03-42ba0c767691 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,273 | supabase-export-v2 | 3f6cd82c77c60567 | .. method:: SMTP.login(user, password, *, initial_response_ok=True)
Log in on an SMTP server that requires authentication. The arguments are the
username and the password to authenticate with. If there has been no previous
``EHLO`` or ``HELO`` command this session, this method tries ESMTP ``EHLO``
first. This method... | trusted_official_docs | CPython Docs | .. method:: SMTP.login(user, password, *, initial_response_ok=True)
Log in on an SMTP server that requires authentication. The arguments are the
username and the password to authenticate with. If there has been no previous
``EHLO`` or ``HELO`` command this session, this method tries ESMTP ``EHLO``
first. This method... | .. method:: SMTP.login(user, password, *, initial_response_ok=True)
Log in on an SMTP server that requires authentication. The arguments are the
username and the password to authenticate with. If there has been no previous
``EHLO`` or ``HELO`` command this session, this method tries ESMTP ``EHLO``
first. This method... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ef279920-769d-4631-beec-b687c1080674 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,269 | supabase-export-v2 | 718af531b5fa40ed | .. method:: SMTP.verify(address)
Check the validity of an address on this server using SMTP ``VRFY``. Returns a
tuple consisting of code 250 and a full :rfc:`822` address (including human
name) if the user address is valid. Otherwise returns an SMTP error code of 400
or greater and an error string. | trusted_official_docs | CPython Docs | .. method:: SMTP.verify(address)
Check the validity of an address on this server using SMTP ``VRFY``. Returns a
tuple consisting of code 250 and a full :rfc:`822` address (including human
name) if the user address is valid. Otherwise returns an SMTP error code of 400
or greater and an error string. | .. method:: SMTP.verify(address)
Check the validity of an address on this server using SMTP ``VRFY``. Returns a
tuple consisting of code 250 and a full :rfc:`822` address (including human
name) if the user address is valid. Otherwise returns an SMTP error code of 400
or greater and an error string. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f00e9488-281b-4117-b3df-0b65cd9671a5 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,188 | supabase-export-v2 | 303beef6ea68c9db | If omitted (or if *host* or *port* are ``''`` and/or ``0`` respectively) the OS default behavior will be used.
For normal use, you should only require the initialization/connect,
:meth:`sendmail`, and :meth:`SMTP.quit` methods. An example is included below. | trusted_official_docs | CPython Docs | If omitted (or if *host* or *port* are ``''`` and/or ``0`` respectively) the OS default behavior will be used.
For normal use, you should only require the initialization/connect,
:meth:`sendmail`, and :meth:`SMTP.quit` methods. An example is included below. | If omitted (or if *host* or *port* are ``''`` and/or ``0`` respectively) the OS default behavior will be used.
For normal use, you should only require the initialization/connect,
:meth:`sendmail`, and :meth:`SMTP.quit` methods. An example is included below. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f1b2c4a9-75f2-4cd9-8aee-763c09e67d17 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,201 | supabase-export-v2 | 158ce746bf5db28a | instances of :class:`SMTP`. :class:`SMTP_SSL` should be used for situations where SSL is required from the beginning of the connection and using :meth:`SMTP.starttls` is not appropriate.
If the host parameter is set to a truthy value, :meth:`SMTP.connect` is called with host
and port automatically when the object is c... | trusted_official_docs | CPython Docs | instances of :class:`SMTP`. :class:`SMTP_SSL` should be used for situations where SSL is required from the beginning of the connection and using :meth:`SMTP.starttls` is not appropriate.
If the host parameter is set to a truthy value, :meth:`SMTP.connect` is called with host
and port automatically when the object is c... | instances of :class:`SMTP`. :class:`SMTP_SSL` should be used for situations where SSL is required from the beginning of the connection and using :meth:`SMTP.starttls` is not appropriate.
If the host parameter is set to a truthy value, :meth:`SMTP.connect` is called with host
and port automatically when the object is c... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f5c7a80e-4c07-4c40-bcad-ac058d9c07da | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,254 | supabase-export-v2 | 7b89b8d76725ca9e | .. method:: SMTP.connect(host='localhost', port=0)
Connect to a host on a given port. The defaults are to connect to the local
host at the standard SMTP port (25). If the hostname ends with a colon (``':'``)
followed by a number, that suffix will be stripped off and the number
interpreted as the port number to use. ... | trusted_official_docs | CPython Docs | .. method:: SMTP.connect(host='localhost', port=0)
Connect to a host on a given port. The defaults are to connect to the local
host at the standard SMTP port (25). If the hostname ends with a colon (``':'``)
followed by a number, that suffix will be stripped off and the number
interpreted as the port number to use. ... | .. method:: SMTP.connect(host='localhost', port=0)
Connect to a host on a given port. The defaults are to connect to the local
host at the standard SMTP port (25). If the hostname ends with a colon (``':'``)
followed by a number, that suffix will be stripped off and the number
interpreted as the port number to use. ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f99a0330-8876-4822-9575-23841a7a4789 | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,211 | supabase-export-v2 | 23952e08b221f062 | .. class:: LMTP(host='', port=LMTP_PORT, local_hostname=None, \ source_address=None[, timeout])
The LMTP protocol, which is very similar to ESMTP, is heavily based on the
standard SMTP client. It's common to use Unix sockets for LMTP, so our
:meth:`~SMTP.connect` method must support that as well as a regular host:por... | trusted_official_docs | CPython Docs | .. class:: LMTP(host='', port=LMTP_PORT, local_hostname=None, \ source_address=None[, timeout])
The LMTP protocol, which is very similar to ESMTP, is heavily based on the
standard SMTP client. It's common to use Unix sockets for LMTP, so our
:meth:`~SMTP.connect` method must support that as well as a regular host:por... | .. class:: LMTP(host='', port=LMTP_PORT, local_hostname=None, \ source_address=None[, timeout])
The LMTP protocol, which is very similar to ESMTP, is heavily based on the
standard SMTP client. It's common to use Unix sockets for LMTP, so our
:meth:`~SMTP.connect` method must support that as well as a regular host:por... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fb3364cd-4793-4a24-abcd-3a100f7dc31c | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,294 | supabase-export-v2 | 8d40419daca1720f | If *keyfile* and *certfile* are provided, they are used to create an :class:`ssl.SSLContext`.
Optional *context* parameter is an :class:`ssl.SSLContext` object; This is
an alternative to using a keyfile and a certfile and if specified both
*keyfile* and *certfile* should be ``None``. | trusted_official_docs | CPython Docs | If *keyfile* and *certfile* are provided, they are used to create an :class:`ssl.SSLContext`.
Optional *context* parameter is an :class:`ssl.SSLContext` object; This is
an alternative to using a keyfile and a certfile and if specified both
*keyfile* and *certfile* should be ``None``. | If *keyfile* and *certfile* are provided, they are used to create an :class:`ssl.SSLContext`.
Optional *context* parameter is an :class:`ssl.SSLContext` object; This is
an alternative to using a keyfile and a certfile and if specified both
*keyfile* and *certfile* should be ``None``. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ff787ffd-64bb-4309-bfb2-a3e1dce579da | CPython Docs | file://datasets/cpython/Doc/library/smtplib.rst | unknown | 5e858b2f-6f9a-41ee-be39-ab8d2cdbd9ba | 32,329 | supabase-export-v2 | af99de291d0f35a1 | ``DATA`` are also supported. Normally these do not need to be called directly, so they are not documented here. For details, consult the module code.
Additionally, an SMTP instance has the following attributes: | trusted_official_docs | CPython Docs | ``DATA`` are also supported. Normally these do not need to be called directly, so they are not documented here. For details, consult the module code.
Additionally, an SMTP instance has the following attributes: | ``DATA`` are also supported. Normally these do not need to be called directly, so they are not documented here. For details, consult the module code.
Additionally, an SMTP instance has the following attributes: | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
00aff519-4ccc-4f7c-a543-14ec430300f2 | CPython Docs | file://datasets/cpython/Doc/library/pickle.rst | unknown | d611e6ff-74a7-41e7-8f39-27f844eb2f66 | 32,614 | supabase-export-v2 | eb050e1edc98a936 | def __reduce_ex__(self, protocol): if protocol >= 5: return type(self)._reconstruct, (PickleBuffer(self),), None else: # PickleBuffer is forbidden with pickle protocols <= 4. return type(self)._reconstruct, (bytearray(self),)
@classmethod
def _reconstruct(cls, obj):
with memoryview(obj) as m:
# Get a handle over the... | trusted_official_docs | CPython Docs | def __reduce_ex__(self, protocol): if protocol >= 5: return type(self)._reconstruct, (PickleBuffer(self),), None else: # PickleBuffer is forbidden with pickle protocols <= 4. return type(self)._reconstruct, (bytearray(self),)
@classmethod
def _reconstruct(cls, obj):
with memoryview(obj) as m:
# Get a handle over the... | def __reduce_ex__(self, protocol): if protocol >= 5: return type(self)._reconstruct, (PickleBuffer(self),), None else: # PickleBuffer is forbidden with pickle protocols <= 4. return type(self)._reconstruct, (bytearray(self),)
@classmethod
def _reconstruct(cls, obj):
with memoryview(obj) as m:
# Get a handle over the... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
010e9692-5935-4041-a673-77e088a453b2 | CPython Docs | file://datasets/cpython/Doc/library/pickle.rst | unknown | d611e6ff-74a7-41e7-8f39-27f844eb2f66 | 32,387 | supabase-export-v2 | 418f740a238d7b4a | and speedup for in-band data. It is the default protocol starting with Python 3.14. Refer to :pep:`574` for information about improvements brought by protocol 5.
.. note::
Serialization is a more primitive notion than persistence; although
:mod:`!pickle` reads and writes file objects, it does not handle the issue of
... | trusted_official_docs | CPython Docs | and speedup for in-band data. It is the default protocol starting with Python 3.14. Refer to :pep:`574` for information about improvements brought by protocol 5.
.. note::
Serialization is a more primitive notion than persistence; although
:mod:`!pickle` reads and writes file objects, it does not handle the issue of
... | and speedup for in-band data. It is the default protocol starting with Python 3.14. Refer to :pep:`574` for information about improvements brought by protocol 5.
.. note::
Serialization is a more primitive notion than persistence; although
:mod:`!pickle` reads and writes file objects, it does not handle the issue of
... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
024377cd-1377-41fd-87d1-c9f54694688d | CPython Docs | file://datasets/cpython/Doc/library/pickle.rst | unknown | d611e6ff-74a7-41e7-8f39-27f844eb2f66 | 32,541 | supabase-export-v2 | fb3fe19446b4bdaf | six items long. Optional items can either be omitted, or ``None`` can be provided as their value. The semantics of each item are in order:
.. XXX Mention __newobj__ special-case? | trusted_official_docs | CPython Docs | six items long. Optional items can either be omitted, or ``None`` can be provided as their value. The semantics of each item are in order:
.. XXX Mention __newobj__ special-case? | six items long. Optional items can either be omitted, or ``None`` can be provided as their value. The semantics of each item are in order:
.. XXX Mention __newobj__ special-case? | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
024c38a9-6ea6-49c3-bcbb-a6d1d99021ff | CPython Docs | file://datasets/cpython/Doc/library/pickle.rst | unknown | d611e6ff-74a7-41e7-8f39-27f844eb2f66 | 32,386 | supabase-export-v2 | d0d946a4fee4d28a | objects, and some data format optimizations. This was the default protocol in Python 3.8--3.13. Refer to :pep:`3154` for information about improvements brought by protocol 4.
* Protocol version 5 was added in Python 3.8. It adds support for out-of-band
data and speedup for in-band data. It is the default protocol star... | trusted_official_docs | CPython Docs | objects, and some data format optimizations. This was the default protocol in Python 3.8--3.13. Refer to :pep:`3154` for information about improvements brought by protocol 4.
* Protocol version 5 was added in Python 3.8. It adds support for out-of-band
data and speedup for in-band data. It is the default protocol star... | objects, and some data format optimizations. This was the default protocol in Python 3.8--3.13. Refer to :pep:`3154` for information about improvements brought by protocol 4.
* Protocol version 5 was added in Python 3.8. It adds support for out-of-band
data and speedup for in-band data. It is the default protocol star... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
028316f1-21c4-4fd4-89e6-effa4d297032 | CPython Docs | file://datasets/cpython/Doc/library/pickle.rst | unknown | d611e6ff-74a7-41e7-8f39-27f844eb2f66 | 32,465 | supabase-export-v2 | 7211f5ba7d5885e0 | 8-bit string instances as bytes objects. Using ``encoding='latin1'`` is required for unpickling NumPy arrays and instances of :class:`~datetime.datetime`, :class:`~datetime.date` and :class:`~datetime.time` pickled by Python 2.
If *buffers* is ``None`` (the default), then all data necessary for
deserialization must be... | trusted_official_docs | CPython Docs | 8-bit string instances as bytes objects. Using ``encoding='latin1'`` is required for unpickling NumPy arrays and instances of :class:`~datetime.datetime`, :class:`~datetime.date` and :class:`~datetime.time` pickled by Python 2.
If *buffers* is ``None`` (the default), then all data necessary for
deserialization must be... | 8-bit string instances as bytes objects. Using ``encoding='latin1'`` is required for unpickling NumPy arrays and instances of :class:`~datetime.datetime`, :class:`~datetime.date` and :class:`~datetime.time` pickled by Python 2.
If *buffers* is ``None`` (the default), then all data necessary for
deserialization must be... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
02d4234d-3b21-4c58-a5cf-02d1bf22f9dc | CPython Docs | file://datasets/cpython/Doc/library/pickle.rst | unknown | d611e6ff-74a7-41e7-8f39-27f844eb2f66 | 32,629 | supabase-export-v2 | a77e29e8eef6b7d5 | global (i.e., a class or a function) is requested. Thus it is possible to either completely forbid globals or restrict them to a safe subset.
Here is an example of an unpickler allowing only few safe classes from the
:mod:`builtins` module to be loaded:: | trusted_official_docs | CPython Docs | global (i.e., a class or a function) is requested. Thus it is possible to either completely forbid globals or restrict them to a safe subset.
Here is an example of an unpickler allowing only few safe classes from the
:mod:`builtins` module to be loaded:: | global (i.e., a class or a function) is requested. Thus it is possible to either completely forbid globals or restrict them to a safe subset.
Here is an example of an unpickler allowing only few safe classes from the
:mod:`builtins` module to be loaded:: | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
030dfaaf-065b-4375-b7c9-78c93e11b311 | CPython Docs | file://datasets/cpython/Doc/library/pickle.rst | unknown | d611e6ff-74a7-41e7-8f39-27f844eb2f66 | 32,667 | supabase-export-v2 | 677d668606349422 | .. [#] This is why :keyword:`lambda` functions cannot be pickled: all :keyword:`!lambda` functions share the same name: ``<lambda>``.
.. [#] The exception raised will likely be an :exc:`ImportError` or an
:exc:`AttributeError` but it could be something else. | trusted_official_docs | CPython Docs | .. [#] This is why :keyword:`lambda` functions cannot be pickled: all :keyword:`!lambda` functions share the same name: ``<lambda>``.
.. [#] The exception raised will likely be an :exc:`ImportError` or an
:exc:`AttributeError` but it could be something else. | .. [#] This is why :keyword:`lambda` functions cannot be pickled: all :keyword:`!lambda` functions share the same name: ``<lambda>``.
.. [#] The exception raised will likely be an :exc:`ImportError` or an
:exc:`AttributeError` but it could be something else. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
03a559bb-2a8c-4701-a8c6-c2172ee3aa22 | CPython Docs | file://datasets/cpython/Doc/library/pickle.rst | unknown | d611e6ff-74a7-41e7-8f39-27f844eb2f66 | 32,443 | supabase-export-v2 | 607cc53a0d0a5d5c | Do nothing by default. This exists so a subclass can override it.
If :meth:`persistent_id` returns ``None``, *obj* is pickled as usual. Any
other value causes :class:`Pickler` to emit the returned value as a
persistent ID for *obj*. The meaning of this persistent ID should be
defined by :meth:`Unpickler.persistent_l... | trusted_official_docs | CPython Docs | Do nothing by default. This exists so a subclass can override it.
If :meth:`persistent_id` returns ``None``, *obj* is pickled as usual. Any
other value causes :class:`Pickler` to emit the returned value as a
persistent ID for *obj*. The meaning of this persistent ID should be
defined by :meth:`Unpickler.persistent_l... | Do nothing by default. This exists so a subclass can override it.
If :meth:`persistent_id` returns ``None``, *obj* is pickled as usual. Any
other value causes :class:`Pickler` to emit the returned value as a
persistent ID for *obj*. The meaning of this persistent ID should be
defined by :meth:`Unpickler.persistent_l... | python, official-docs, cpython, P0 | Local_Trusted_Corpus |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.