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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
f407ba37-f97e-4733-8d85-1cb6d1437013 | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,087 | supabase-export-v2 | 156bc39f0ca88e1d | string is present but not followed by a command-line argument. In this case the value from const_ will be produced. Some examples to illustrate this::
>>> parser = argparse.ArgumentParser()
>>> parser.add_argument('--foo', nargs='?', const='c', default='d')
>>> parser.add_argument('bar', nargs='?', default='d')
>>> ... | trusted_official_docs | CPython Docs | string is present but not followed by a command-line argument. In this case the value from const_ will be produced. Some examples to illustrate this::
>>> parser = argparse.ArgumentParser()
>>> parser.add_argument('--foo', nargs='?', const='c', default='d')
>>> parser.add_argument('bar', nargs='?', default='d')
>>> ... | string is present but not followed by a command-line argument. In this case the value from const_ will be produced. Some examples to illustrate this::
>>> parser = argparse.ArgumentParser()
>>> parser.add_argument('--foo', nargs='?', const='c', default='d')
>>> parser.add_argument('bar', nargs='?', default='d')
>>> ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f427bc36-dccb-47f8-9cfd-16735a0de005 | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,018 | supabase-export-v2 | 6efe0626c9e27d8f | color ^^^^^
By default, the help message is printed in color using `ANSI escape sequences
<https://en.wikipedia.org/wiki/ANSI_escape_code>`__. If you want plain text help messages, you can disable this :ref:`in your local
environment <using-on-controlling-color>`, or in the argument parser itself
by setting ``color`` t... | trusted_official_docs | CPython Docs | color ^^^^^
By default, the help message is printed in color using `ANSI escape sequences
<https://en.wikipedia.org/wiki/ANSI_escape_code>`__. If you want plain text help messages, you can disable this :ref:`in your local
environment <using-on-controlling-color>`, or in the argument parser itself
by setting ``color`` t... | color ^^^^^
By default, the help message is printed in color using `ANSI escape sequences
<https://en.wikipedia.org/wiki/ANSI_escape_code>`__. If you want plain text help messages, you can disable this :ref:`in your local
environment <using-on-controlling-color>`, or in the argument parser itself
by setting ``color`` t... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f62330d0-f269-43f3-9477-2b05150f6705 | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,314 | supabase-export-v2 | bb4f552ea316946d | group: bar bar help --foo FOO foo help
The :meth:`add_argument_group` method returns an argument group object which
has an :meth:`~ArgumentParser.add_argument` method just like a regular
:class:`ArgumentParser`. When an argument is added to the group, the parser
treats it just like a normal argument, but displays th... | trusted_official_docs | CPython Docs | group: bar bar help --foo FOO foo help
The :meth:`add_argument_group` method returns an argument group object which
has an :meth:`~ArgumentParser.add_argument` method just like a regular
:class:`ArgumentParser`. When an argument is added to the group, the parser
treats it just like a normal argument, but displays th... | group: bar bar help --foo FOO foo help
The :meth:`add_argument_group` method returns an argument group object which
has an :meth:`~ArgumentParser.add_argument` method just like a regular
:class:`ArgumentParser`. When an argument is added to the group, the parser
treats it just like a normal argument, but displays th... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f911e6bb-8be3-4794-a4c9-d8f721ba335a | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,191 | supabase-export-v2 | d333c93c04b65e50 | that was used to invoke this action. The ``option_string`` argument is optional, and will be absent if the action is associated with a positional argument.
The :meth:`!__call__` method may perform arbitrary actions, but will typically set
attributes on the ``namespace`` based on ``dest`` and ``values``. | trusted_official_docs | CPython Docs | that was used to invoke this action. The ``option_string`` argument is optional, and will be absent if the action is associated with a positional argument.
The :meth:`!__call__` method may perform arbitrary actions, but will typically set
attributes on the ``namespace`` based on ``dest`` and ``values``. | that was used to invoke this action. The ``option_string`` argument is optional, and will be absent if the action is associated with a positional argument.
The :meth:`!__call__` method may perform arbitrary actions, but will typically set
attributes on the ``namespace`` based on ``dest`` and ``values``. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fa07f578-f9a4-453b-a37b-145dd353de62 | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,166 | supabase-export-v2 | 26af440af8a207e5 | of ``nargs`` may cause the metavar to be used multiple times. Providing a tuple to ``metavar`` specifies a different display for each of the arguments::
>>> parser = argparse.ArgumentParser(prog='PROG')
>>> parser.add_argument('-x', nargs=2)
>>> parser.add_argument('--foo', nargs=2, metavar=('bar', 'baz'))
>>> parse... | trusted_official_docs | CPython Docs | of ``nargs`` may cause the metavar to be used multiple times. Providing a tuple to ``metavar`` specifies a different display for each of the arguments::
>>> parser = argparse.ArgumentParser(prog='PROG')
>>> parser.add_argument('-x', nargs=2)
>>> parser.add_argument('--foo', nargs=2, metavar=('bar', 'baz'))
>>> parse... | of ``nargs`` may cause the metavar to be used multiple times. Providing a tuple to ``metavar`` specifies a different display for each of the arguments::
>>> parser = argparse.ArgumentParser(prog='PROG')
>>> parser.add_argument('-x', nargs=2)
>>> parser.add_argument('--foo', nargs=2, metavar=('bar', 'baz'))
>>> parse... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fa7ee54a-0d0e-45ca-8908-d5f3f0ce8351 | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,104 | supabase-export-v2 | b0641346f968605b | the command-line argument is not present. For optional arguments, the ``default`` value is used when the option string was not present at the command line::
>>> parser = argparse.ArgumentParser()
>>> parser.add_argument('--foo', default=42)
>>> parser.parse_args(['--foo', '2'])
Namespace(foo='2')
>>> parser.parse_a... | trusted_official_docs | CPython Docs | the command-line argument is not present. For optional arguments, the ``default`` value is used when the option string was not present at the command line::
>>> parser = argparse.ArgumentParser()
>>> parser.add_argument('--foo', default=42)
>>> parser.parse_args(['--foo', '2'])
Namespace(foo='2')
>>> parser.parse_a... | the command-line argument is not present. For optional arguments, the ``default`` value is used when the option string was not present at the command line::
>>> parser = argparse.ArgumentParser()
>>> parser.add_argument('--foo', default=42)
>>> parser.parse_args(['--foo', '2'])
Namespace(foo='2')
>>> parser.parse_a... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fac0e149-a1bd-445c-b916-b72aeef6a2ba | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,206 | supabase-export-v2 | fe9b2e36567464d8 | * args_ - List of strings to parse. The default is taken from :data:`sys.argv`.
* namespace_ - An object to take the attributes. The default is a new empty
:class:`Namespace` object. | trusted_official_docs | CPython Docs | * args_ - List of strings to parse. The default is taken from :data:`sys.argv`.
* namespace_ - An object to take the attributes. The default is a new empty
:class:`Namespace` object. | * args_ - List of strings to parse. The default is taken from :data:`sys.argv`.
* namespace_ - An object to take the attributes. The default is a new empty
:class:`Namespace` object. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fb199f0a-6b1a-403e-a289-9278c3add0b3 | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 20,978 | supabase-export-v2 | 40165903ab94229f | >>> with open('args.txt', 'w', encoding=sys.getfilesystemencoding()) as fp: ... fp.write('-f\nbar') ... >>> parser = argparse.ArgumentParser(fromfile_prefix_chars='@') >>> parser.add_argument('-f') >>> parser.parse_args(['-f', 'foo', '@args.txt']) Namespace(f='bar')
Arguments read from a file must be one per line by de... | trusted_official_docs | CPython Docs | >>> with open('args.txt', 'w', encoding=sys.getfilesystemencoding()) as fp: ... fp.write('-f\nbar') ... >>> parser = argparse.ArgumentParser(fromfile_prefix_chars='@') >>> parser.add_argument('-f') >>> parser.parse_args(['-f', 'foo', '@args.txt']) Namespace(f='bar')
Arguments read from a file must be one per line by de... | >>> with open('args.txt', 'w', encoding=sys.getfilesystemencoding()) as fp: ... fp.write('-f\nbar') ... >>> parser = argparse.ArgumentParser(fromfile_prefix_chars='@') >>> parser.add_argument('-f') >>> parser.parse_args(['-f', 'foo', '@args.txt']) Namespace(f='bar')
Arguments read from a file must be one per line by de... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fb4fc37e-fa8b-4916-9385-b71abafdf32b | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,167 | supabase-export-v2 | 4ca5ecba0b849132 | >>> parser = argparse.ArgumentParser(prog='PROG') >>> parser.add_argument('-x', nargs=2) >>> parser.add_argument('--foo', nargs=2, metavar=('bar', 'baz')) >>> parser.print_help() usage: PROG [-h] [-x X X] [--foo bar baz]
options:
-h, --help show this help message and exit
-x X X
--foo bar baz | trusted_official_docs | CPython Docs | >>> parser = argparse.ArgumentParser(prog='PROG') >>> parser.add_argument('-x', nargs=2) >>> parser.add_argument('--foo', nargs=2, metavar=('bar', 'baz')) >>> parser.print_help() usage: PROG [-h] [-x X X] [--foo bar baz]
options:
-h, --help show this help message and exit
-x X X
--foo bar baz | >>> parser = argparse.ArgumentParser(prog='PROG') >>> parser.add_argument('-x', nargs=2) >>> parser.add_argument('--foo', nargs=2, metavar=('bar', 'baz')) >>> parser.print_help() usage: PROG [-h] [-x X X] [--foo bar baz]
options:
-h, --help show this help message and exit
-x X X
--foo bar baz | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fb7f2605-a696-4b92-856b-97e6f6829176 | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,262 | supabase-export-v2 | c655a67d2b6d49cb | * required_ - Whether or not a subcommand must be provided, by default ``False`` (added in 3.7)
* help_ - help for sub-parser group in help output, by default ``None`` | trusted_official_docs | CPython Docs | * required_ - Whether or not a subcommand must be provided, by default ``False`` (added in 3.7)
* help_ - help for sub-parser group in help output, by default ``None`` | * required_ - Whether or not a subcommand must be provided, by default ``False`` (added in 3.7)
* help_ - help for sub-parser group in help output, by default ``None`` | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fbbfce86-a7d6-4e1f-b4b5-93dd5def629e | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,096 | supabase-export-v2 | 4a1f0723590c6999 | argparse.ArgumentParser(prog='PROG') >>> parser.add_argument('foo', nargs='+') >>> parser.parse_args(['a', 'b']) Namespace(foo=['a', 'b']) >>> parser.parse_args([]) usage: PROG [-h] foo [foo ...] PROG: error: the following arguments are required: foo
If the ``nargs`` keyword argument is not provided, the number of argu... | trusted_official_docs | CPython Docs | argparse.ArgumentParser(prog='PROG') >>> parser.add_argument('foo', nargs='+') >>> parser.parse_args(['a', 'b']) Namespace(foo=['a', 'b']) >>> parser.parse_args([]) usage: PROG [-h] foo [foo ...] PROG: error: the following arguments are required: foo
If the ``nargs`` keyword argument is not provided, the number of argu... | argparse.ArgumentParser(prog='PROG') >>> parser.add_argument('foo', nargs='+') >>> parser.parse_args(['a', 'b']) Namespace(foo=['a', 'b']) >>> parser.parse_args([]) usage: PROG [-h] foo [foo ...] PROG: error: the following arguments are required: foo
If the ``nargs`` keyword argument is not provided, the number of argu... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fbce1096-9137-402f-b279-5de9d800388b | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,165 | supabase-export-v2 | ff3f64895eea3bb7 | Note that ``metavar`` only changes the *displayed* name - the name of the attribute on the :meth:`~ArgumentParser.parse_args` object is still determined by the dest_ value.
Different values of ``nargs`` may cause the metavar to be used multiple times. Providing a tuple to ``metavar`` specifies a different display for e... | trusted_official_docs | CPython Docs | Note that ``metavar`` only changes the *displayed* name - the name of the attribute on the :meth:`~ArgumentParser.parse_args` object is still determined by the dest_ value.
Different values of ``nargs`` may cause the metavar to be used multiple times. Providing a tuple to ``metavar`` specifies a different display for e... | Note that ``metavar`` only changes the *displayed* name - the name of the attribute on the :meth:`~ArgumentParser.parse_args` object is still determined by the dest_ value.
Different values of ``nargs`` may cause the metavar to be used multiple times. Providing a tuple to ``metavar`` specifies a different display for e... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fd5ccfe7-ddc0-47b9-aa11-f2c480a71fe7 | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,127 | supabase-export-v2 | b26f9621c614e2dd | See :class:`BooleanOptionalAction` or ``action='store_true'`` for common alternatives.
In general, the ``type`` keyword is a convenience that should only be used for
simple conversions that can only raise one of the three supported exceptions. Anything with more interesting error-handling or resource management should ... | trusted_official_docs | CPython Docs | See :class:`BooleanOptionalAction` or ``action='store_true'`` for common alternatives.
In general, the ``type`` keyword is a convenience that should only be used for
simple conversions that can only raise one of the three supported exceptions. Anything with more interesting error-handling or resource management should ... | See :class:`BooleanOptionalAction` or ``action='store_true'`` for common alternatives.
In general, the ``type`` keyword is a convenience that should only be used for
simple conversions that can only raise one of the three supported exceptions. Anything with more interesting error-handling or resource management should ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ff6e9851-b6c0-4969-9ee2-bac3a9036ceb | CPython Docs | file://datasets/cpython/Doc/library/argparse.rst | unknown | 001a8019-557f-4048-beb6-3b9035272f92 | 21,286 | supabase-export-v2 | 83d031fe59fe14c2 | However, if it is necessary to check the name of the subparser that was invoked, the ``dest`` keyword argument to the :meth:`~ArgumentParser.add_subparsers` call will work::
>>> parser = argparse.ArgumentParser()
>>> subparsers = parser.add_subparsers(dest='subparser_name')
>>> subparser1 = subparsers.add_parser('1')... | trusted_official_docs | CPython Docs | However, if it is necessary to check the name of the subparser that was invoked, the ``dest`` keyword argument to the :meth:`~ArgumentParser.add_subparsers` call will work::
>>> parser = argparse.ArgumentParser()
>>> subparsers = parser.add_subparsers(dest='subparser_name')
>>> subparser1 = subparsers.add_parser('1')... | However, if it is necessary to check the name of the subparser that was invoked, the ``dest`` keyword argument to the :meth:`~ArgumentParser.add_subparsers` call will work::
>>> parser = argparse.ArgumentParser()
>>> subparsers = parser.add_subparsers(dest='subparser_name')
>>> subparser1 = subparsers.add_parser('1')... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
51963bf7-f0be-471b-8f4a-ba2f21359372 | CPython Docs | file://datasets/cpython/Doc/library/nntplib.rst | unknown | 3e73ba2c-1ae9-4fb6-bf17-bd6e5597b9b4 | 21,401 | supabase-export-v2 | 56054e2ebd686aa2 | part of the Python standard library. It was :ref:`removed in Python 3.13 <whatsnew313-pep594>` after being deprecated in Python 3.11. The removal was decided in :pep:`594`.
The last version of Python that provided the :mod:`!nntplib` module was
`Python 3.12 <https://docs.python.org/3.12/library/nntplib.html>`_. | trusted_official_docs | CPython Docs | part of the Python standard library. It was :ref:`removed in Python 3.13 <whatsnew313-pep594>` after being deprecated in Python 3.11. The removal was decided in :pep:`594`.
The last version of Python that provided the :mod:`!nntplib` module was
`Python 3.12 <https://docs.python.org/3.12/library/nntplib.html>`_. | part of the Python standard library. It was :ref:`removed in Python 3.13 <whatsnew313-pep594>` after being deprecated in Python 3.11. The removal was decided in :pep:`594`.
The last version of Python that provided the :mod:`!nntplib` module was
`Python 3.12 <https://docs.python.org/3.12/library/nntplib.html>`_. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
dfc6f3f9-4dad-4c71-8065-49fef3c7836b | CPython Docs | file://datasets/cpython/Doc/library/markup.rst | unknown | 543659ca-19c0-4a65-803e-d7c303e17b7a | 21,403 | supabase-export-v2 | 1e448a11c4c8b971 | ********************************** Structured Markup Processing Tools **********************************
Python supports a variety of modules to work with various forms of structured
data markup. This includes modules to work with the Standard Generalized Markup
Language (SGML) and the Hypertext Markup Language (HTML),... | trusted_official_docs | CPython Docs | ********************************** Structured Markup Processing Tools **********************************
Python supports a variety of modules to work with various forms of structured
data markup. This includes modules to work with the Standard Generalized Markup
Language (SGML) and the Hypertext Markup Language (HTML),... | ********************************** Structured Markup Processing Tools **********************************
Python supports a variety of modules to work with various forms of structured
data markup. This includes modules to work with the Standard Generalized Markup
Language (SGML) and the Hypertext Markup Language (HTML),... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
01edf02a-a0c7-42b3-a9f1-1b5d5eba153f | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,418 | supabase-export-v2 | 9810e77e4479511d | past comparisons and the results, with cache entries invalidated if the :func:`os.stat` information for the file changes. The entire cache may be cleared using :func:`clear_cache`.
.. function:: cmpfiles(dir1, dir2, common, shallow=True) | trusted_official_docs | CPython Docs | past comparisons and the results, with cache entries invalidated if the :func:`os.stat` information for the file changes. The entire cache may be cleared using :func:`clear_cache`.
.. function:: cmpfiles(dir1, dir2, common, shallow=True) | past comparisons and the results, with cache entries invalidated if the :func:`os.stat` information for the file changes. The entire cache may be cleared using :func:`clear_cache`.
.. function:: cmpfiles(dir1, dir2, common, shallow=True) | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
217cac3e-a91b-47be-ae21-848ac47908c7 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,420 | supabase-export-v2 | 80d0840d9337b784 | Compare the files in the two directories *dir1* and *dir2* whose names are given by *common*.
Returns three lists of file names: *match*, *mismatch*,
*errors*. *match* contains the list of files that match, *mismatch* contains
the names of those that don't, and *errors* lists the names of files which
could not be co... | trusted_official_docs | CPython Docs | Compare the files in the two directories *dir1* and *dir2* whose names are given by *common*.
Returns three lists of file names: *match*, *mismatch*,
*errors*. *match* contains the list of files that match, *mismatch* contains
the names of those that don't, and *errors* lists the names of files which
could not be co... | Compare the files in the two directories *dir1* and *dir2* whose names are given by *common*.
Returns three lists of file names: *match*, *mismatch*,
*errors*. *match* contains the list of files that match, *mismatch* contains
the names of those that don't, and *errors* lists the names of files which
could not be co... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
2408fba7-1f37-423f-96a2-561d9f8b4e85 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,422 | supabase-export-v2 | 2f296ac44ac807a7 | The *shallow* parameter has the same meaning and default value as for :func:`filecmp.cmp`.
For example, ``cmpfiles('a', 'b', ['c', 'd/e'])`` will compare ``a/c`` with
``b/c`` and ``a/d/e`` with ``b/d/e``. ``'c'`` and ``'d/e'`` will each be in
one of the three returned lists. | trusted_official_docs | CPython Docs | The *shallow* parameter has the same meaning and default value as for :func:`filecmp.cmp`.
For example, ``cmpfiles('a', 'b', ['c', 'd/e'])`` will compare ``a/c`` with
``b/c`` and ``a/d/e`` with ``b/d/e``. ``'c'`` and ``'d/e'`` will each be in
one of the three returned lists. | The *shallow* parameter has the same meaning and default value as for :func:`filecmp.cmp`.
For example, ``cmpfiles('a', 'b', ['c', 'd/e'])`` will compare ``a/c`` with
``b/c`` and ``a/d/e`` with ``b/d/e``. ``'c'`` and ``'d/e'`` will each be in
one of the three returned lists. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
2576a7d2-ebdc-42ff-9623-e35eaaf36285 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,465 | supabase-export-v2 | 2b93c6ad0c5bfb29 | A dictionary mapping names in :attr:`common_dirs` to :class:`dircmp` instances (or MyDirCmp instances if this instance is of type MyDirCmp, a subclass of :class:`dircmp`).
.. versionchanged:: 3.10
Previously entries were always :class:`dircmp` instances. Now entries
are the same type as *self*, if *self* is a subclas... | trusted_official_docs | CPython Docs | A dictionary mapping names in :attr:`common_dirs` to :class:`dircmp` instances (or MyDirCmp instances if this instance is of type MyDirCmp, a subclass of :class:`dircmp`).
.. versionchanged:: 3.10
Previously entries were always :class:`dircmp` instances. Now entries
are the same type as *self*, if *self* is a subclas... | A dictionary mapping names in :attr:`common_dirs` to :class:`dircmp` instances (or MyDirCmp instances if this instance is of type MyDirCmp, a subclass of :class:`dircmp`).
.. versionchanged:: 3.10
Previously entries were always :class:`dircmp` instances. Now entries
are the same type as *self*, if *self* is a subclas... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
347ff0f3-f744-47ac-9909-7056a152a224 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,424 | supabase-export-v2 | 4c441a1814902368 | .. function:: clear_cache()
Clear the filecmp cache. This may be useful if a file is compared so quickly
after it is modified that it is within the mtime resolution of
the underlying filesystem. | trusted_official_docs | CPython Docs | .. function:: clear_cache()
Clear the filecmp cache. This may be useful if a file is compared so quickly
after it is modified that it is within the mtime resolution of
the underlying filesystem. | .. function:: clear_cache()
Clear the filecmp cache. This may be useful if a file is compared so quickly
after it is modified that it is within the mtime resolution of
the underlying filesystem. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
49a661ff-1c11-47fc-a2ba-18a9158983a9 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,469 | supabase-export-v2 | 3bead948a083e60d | Here is a simplified example of using the ``subdirs`` attribute to search recursively through two directories to show common different files::
>>> from filecmp import dircmp
>>> def print_diff_files(dcmp):
... for name in dcmp.diff_files:
... print("diff_file %s found in %s and %s" % (name, dcmp.left,
... dcmp.righ... | trusted_official_docs | CPython Docs | Here is a simplified example of using the ``subdirs`` attribute to search recursively through two directories to show common different files::
>>> from filecmp import dircmp
>>> def print_diff_files(dcmp):
... for name in dcmp.diff_files:
... print("diff_file %s found in %s and %s" % (name, dcmp.left,
... dcmp.righ... | Here is a simplified example of using the ``subdirs`` attribute to search recursively through two directories to show common different files::
>>> from filecmp import dircmp
>>> def print_diff_files(dcmp):
... for name in dcmp.diff_files:
... print("diff_file %s found in %s and %s" % (name, dcmp.left,
... dcmp.righ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
509ba786-749a-4403-9d71-03df16648af9 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,439 | supabase-export-v2 | 212b06bfe5864474 | Print a comparison between *a* and *b* and common subdirectories (recursively).
The :class:`dircmp` class offers a number of interesting attributes that may be
used to get various bits of information about the directory trees being
compared. | trusted_official_docs | CPython Docs | Print a comparison between *a* and *b* and common subdirectories (recursively).
The :class:`dircmp` class offers a number of interesting attributes that may be
used to get various bits of information about the directory trees being
compared. | Print a comparison between *a* and *b* and common subdirectories (recursively).
The :class:`dircmp` class offers a number of interesting attributes that may be
used to get various bits of information about the directory trees being
compared. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
8850cc62-430c-4526-b9a4-6b2f1017b311 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,440 | supabase-export-v2 | e24cda83ffd49328 | The :class:`dircmp` class offers a number of interesting attributes that may be used to get various bits of information about the directory trees being compared.
Note that via :meth:`~object.__getattr__` hooks, all attributes are computed lazily,
so there is no speed penalty if only those attributes which are lightwei... | trusted_official_docs | CPython Docs | The :class:`dircmp` class offers a number of interesting attributes that may be used to get various bits of information about the directory trees being compared.
Note that via :meth:`~object.__getattr__` hooks, all attributes are computed lazily,
so there is no speed penalty if only those attributes which are lightwei... | The :class:`dircmp` class offers a number of interesting attributes that may be used to get various bits of information about the directory trees being compared.
Note that via :meth:`~object.__getattr__` hooks, all attributes are computed lazily,
so there is no speed penalty if only those attributes which are lightwei... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
8ceb2396-7492-42bb-9abb-d826e7bd1508 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,417 | supabase-export-v2 | 5f6d92ca247891a0 | Note that no external programs are called from this function, giving it portability and efficiency.
This function uses a cache for past comparisons and the results,
with cache entries invalidated if the :func:`os.stat` information for the
file changes. The entire cache may be cleared using :func:`clear_cache`. | trusted_official_docs | CPython Docs | Note that no external programs are called from this function, giving it portability and efficiency.
This function uses a cache for past comparisons and the results,
with cache entries invalidated if the :func:`os.stat` information for the
file changes. The entire cache may be cleared using :func:`clear_cache`. | Note that no external programs are called from this function, giving it portability and efficiency.
This function uses a cache for past comparisons and the results,
with cache entries invalidated if the :func:`os.stat` information for the
file changes. The entire cache may be cleared using :func:`clear_cache`. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
a9a577f4-0bd4-4460-8d1a-3745d5998b31 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,421 | supabase-export-v2 | dc13fe0c8aa4d41e | exist in one of the directories, the user lacks permission to read them or if the comparison could not be done for some other reason.
The *shallow* parameter has the same meaning and default value as for
:func:`filecmp.cmp`. | trusted_official_docs | CPython Docs | exist in one of the directories, the user lacks permission to read them or if the comparison could not be done for some other reason.
The *shallow* parameter has the same meaning and default value as for
:func:`filecmp.cmp`. | exist in one of the directories, the user lacks permission to read them or if the comparison could not be done for some other reason.
The *shallow* parameter has the same meaning and default value as for
:func:`filecmp.cmp`. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
acaf3bba-b0ee-4e25-a7b0-8731bbefd16f | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,411 | supabase-export-v2 | 24fe9c85695c11a3 | The :mod:`!filecmp` module defines functions to compare files and directories, with various optional time/correctness trade-offs. For comparing files, see also the :mod:`difflib` module.
The :mod:`!filecmp` module defines the following functions: | trusted_official_docs | CPython Docs | The :mod:`!filecmp` module defines functions to compare files and directories, with various optional time/correctness trade-offs. For comparing files, see also the :mod:`difflib` module.
The :mod:`!filecmp` module defines the following functions: | The :mod:`!filecmp` module defines functions to compare files and directories, with various optional time/correctness trade-offs. For comparing files, see also the :mod:`difflib` module.
The :mod:`!filecmp` module defines the following functions: | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ddc97c82-534b-4acb-99aa-21ad89799164 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,429 | supabase-export-v2 | d6c9ad69e08f8896 | *ignore* is a list of names to ignore, and defaults to :const:`filecmp.DEFAULT_IGNORES`. *hide* is a list of names to hide, and defaults to ``[os.curdir, os.pardir]``.
The :class:`dircmp` class compares files by doing *shallow* comparisons
as described for :func:`filecmp.cmp` by default using the *shallow*
parameter. | trusted_official_docs | CPython Docs | *ignore* is a list of names to ignore, and defaults to :const:`filecmp.DEFAULT_IGNORES`. *hide* is a list of names to hide, and defaults to ``[os.curdir, os.pardir]``.
The :class:`dircmp` class compares files by doing *shallow* comparisons
as described for :func:`filecmp.cmp` by default using the *shallow*
parameter. | *ignore* is a list of names to ignore, and defaults to :const:`filecmp.DEFAULT_IGNORES`. *hide* is a list of names to hide, and defaults to ``[os.curdir, os.pardir]``.
The :class:`dircmp` class compares files by doing *shallow* comparisons
as described for :func:`filecmp.cmp` by default using the *shallow*
parameter. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ecb85c42-39eb-4be6-974a-46141cb43493 | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,414 | supabase-export-v2 | 448b4ada20b9422a | Compare the files named *f1* and *f2*, returning ``True`` if they seem equal, ``False`` otherwise.
If *shallow* is true and the :func:`os.stat` signatures (file type, size, and
modification time) of both files are identical, the files are taken to be
equal. | trusted_official_docs | CPython Docs | Compare the files named *f1* and *f2*, returning ``True`` if they seem equal, ``False`` otherwise.
If *shallow* is true and the :func:`os.stat` signatures (file type, size, and
modification time) of both files are identical, the files are taken to be
equal. | Compare the files named *f1* and *f2*, returning ``True`` if they seem equal, ``False`` otherwise.
If *shallow* is true and the :func:`os.stat` signatures (file type, size, and
modification time) of both files are identical, the files are taken to be
equal. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f1de5117-916a-427b-95a3-01c0131fc5bf | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,415 | supabase-export-v2 | c319128bcfb7a816 | *shallow* is true and the :func:`os.stat` signatures (file type, size, and modification time) of both files are identical, the files are taken to be equal.
Otherwise, the files are treated as different if their sizes or contents differ. | trusted_official_docs | CPython Docs | *shallow* is true and the :func:`os.stat` signatures (file type, size, and modification time) of both files are identical, the files are taken to be equal.
Otherwise, the files are treated as different if their sizes or contents differ. | *shallow* is true and the :func:`os.stat` signatures (file type, size, and modification time) of both files are identical, the files are taken to be equal.
Otherwise, the files are treated as different if their sizes or contents differ. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fda0e341-b1ae-42bc-bbcd-750fb2fae6ca | CPython Docs | file://datasets/cpython/Doc/library/filecmp.rst | unknown | b9fb8d6a-4487-4e44-86ab-6d5e830b2d86 | 21,428 | supabase-export-v2 | 8b324593c96f56bb | .. class:: dircmp(a, b, ignore=None, hide=None, *, shallow=True)
Construct a new directory comparison object, to compare the directories *a*
and *b*. *ignore* is a list of names to ignore, and defaults to
:const:`filecmp.DEFAULT_IGNORES`. *hide* is a list of names to hide, and
defaults to ``[os.curdir, os.pardir]``. | trusted_official_docs | CPython Docs | .. class:: dircmp(a, b, ignore=None, hide=None, *, shallow=True)
Construct a new directory comparison object, to compare the directories *a*
and *b*. *ignore* is a list of names to ignore, and defaults to
:const:`filecmp.DEFAULT_IGNORES`. *hide* is a list of names to hide, and
defaults to ``[os.curdir, os.pardir]``. | .. class:: dircmp(a, b, ignore=None, hide=None, *, shallow=True)
Construct a new directory comparison object, to compare the directories *a*
and *b*. *ignore* is a list of names to ignore, and defaults to
:const:`filecmp.DEFAULT_IGNORES`. *hide* is a list of names to hide, and
defaults to ``[os.curdir, os.pardir]``. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
02cd3b9e-b62d-4330-a9d6-7e811eb901bc | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,493 | supabase-export-v2 | d93ce095bb8a2b8e | bitwise OR of :const:`os.O_APPEND`, :const:`os.O_RDONLY`, :const:`os.O_TEXT` and :const:`os.O_NOINHERIT`. The returned file descriptor may be used as a parameter to :func:`os.fdopen` to create a file object.
The file descriptor is inheritable by default. Pass :const:`os.O_NOINHERIT`
flag to make it non inheritable. | trusted_official_docs | CPython Docs | bitwise OR of :const:`os.O_APPEND`, :const:`os.O_RDONLY`, :const:`os.O_TEXT` and :const:`os.O_NOINHERIT`. The returned file descriptor may be used as a parameter to :func:`os.fdopen` to create a file object.
The file descriptor is inheritable by default. Pass :const:`os.O_NOINHERIT`
flag to make it non inheritable. | bitwise OR of :const:`os.O_APPEND`, :const:`os.O_RDONLY`, :const:`os.O_TEXT` and :const:`os.O_NOINHERIT`. The returned file descriptor may be used as a parameter to :func:`os.fdopen` to create a file object.
The file descriptor is inheritable by default. Pass :const:`os.O_NOINHERIT`
flag to make it non inheritable. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
193e9a85-0f22-4ea9-96bf-42a2d5237a5c | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,530 | supabase-export-v2 | 12aa76a075618d26 | .. function:: CrtSetReportMode(type, mode)
Specifies the destination or destinations for a specific report type
generated by :c:func:`!_CrtDbgReport` in the MS VC++ runtime. *type* must be
one of the :const:`!CRT_\*` constants listed below. *mode* must be one of the
:const:`!CRTDBG_\*` constants listed below. Only a... | trusted_official_docs | CPython Docs | .. function:: CrtSetReportMode(type, mode)
Specifies the destination or destinations for a specific report type
generated by :c:func:`!_CrtDbgReport` in the MS VC++ runtime. *type* must be
one of the :const:`!CRT_\*` constants listed below. *mode* must be one of the
:const:`!CRTDBG_\*` constants listed below. Only a... | .. function:: CrtSetReportMode(type, mode)
Specifies the destination or destinations for a specific report type
generated by :c:func:`!_CrtDbgReport` in the MS VC++ runtime. *type* must be
one of the :const:`!CRT_\*` constants listed below. *mode* must be one of the
:const:`!CRTDBG_\*` constants listed below. Only a... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
27f35f78-9e5b-42a4-a972-2e7f9399c239 | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,481 | supabase-export-v2 | a068efe3ea4e97bb | .. function:: locking(fd, mode, nbytes)
Lock part of a file based on file descriptor *fd* from the C runtime. Raises
:exc:`OSError` on failure. The locked region of the file extends from the
current file position for *nbytes* bytes, and may continue beyond the end of the
file. *mode* must be one of the :const:`!LK_\... | trusted_official_docs | CPython Docs | .. function:: locking(fd, mode, nbytes)
Lock part of a file based on file descriptor *fd* from the C runtime. Raises
:exc:`OSError` on failure. The locked region of the file extends from the
current file position for *nbytes* bytes, and may continue beyond the end of the
file. *mode* must be one of the :const:`!LK_\... | .. function:: locking(fd, mode, nbytes)
Lock part of a file based on file descriptor *fd* from the C runtime. Raises
:exc:`OSError` on failure. The locked region of the file extends from the
current file position for *nbytes* bytes, and may continue beyond the end of the
file. *mode* must be one of the :const:`!LK_\... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
5c28ed93-e23d-40ad-bef2-57652d605bf0 | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,520 | supabase-export-v2 | e81ceaf558a6b7a4 | .. function:: set_error_mode(mode)
Changes the location where the C runtime writes an error message for an error
that might end the program. *mode* must be one of the :const:`!OUT_\*`
constants listed below or :const:`REPORT_ERRMODE`. Returns the old setting
or -1 if an error occurs. Only available in
:ref:`debug b... | trusted_official_docs | CPython Docs | .. function:: set_error_mode(mode)
Changes the location where the C runtime writes an error message for an error
that might end the program. *mode* must be one of the :const:`!OUT_\*`
constants listed below or :const:`REPORT_ERRMODE`. Returns the old setting
or -1 if an error occurs. Only available in
:ref:`debug b... | .. function:: set_error_mode(mode)
Changes the location where the C runtime writes an error message for an error
that might end the program. *mode* must be one of the :const:`!OUT_\*`
constants listed below or :const:`REPORT_ERRMODE`. Returns the old setting
or -1 if an error occurs. Only available in
:ref:`debug b... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
8688f635-8e16-4031-b98d-fe9a745d36e8 | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,501 | supabase-export-v2 | bcb9c42aec73cdc0 | .. function:: getch()
Read a keypress and return the resulting character as a byte string. Nothing is echoed to the console. This call will block if a keypress
is not already available, but will not wait for :kbd:`Enter` to be
pressed. If the pressed key was a special function key, this will
return ``'\000'`` or ``'... | trusted_official_docs | CPython Docs | .. function:: getch()
Read a keypress and return the resulting character as a byte string. Nothing is echoed to the console. This call will block if a keypress
is not already available, but will not wait for :kbd:`Enter` to be
pressed. If the pressed key was a special function key, this will
return ``'\000'`` or ``'... | .. function:: getch()
Read a keypress and return the resulting character as a byte string. Nothing is echoed to the console. This call will block if a keypress
is not already available, but will not wait for :kbd:`Enter` to be
pressed. If the pressed key was a special function key, this will
return ``'\000'`` or ``'... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
9fea0414-f8d0-4901-940f-99c96cf6a3cb | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,490 | supabase-export-v2 | 77281ddc91c47085 | .. function:: setmode(fd, flags)
Set the line-end translation mode for the file descriptor *fd*. To set it to
text mode, *flags* should be :const:`os.O_TEXT`; for binary, it should be
:const:`os.O_BINARY`. | trusted_official_docs | CPython Docs | .. function:: setmode(fd, flags)
Set the line-end translation mode for the file descriptor *fd*. To set it to
text mode, *flags* should be :const:`os.O_TEXT`; for binary, it should be
:const:`os.O_BINARY`. | .. function:: setmode(fd, flags)
Set the line-end translation mode for the file descriptor *fd*. To set it to
text mode, *flags* should be :const:`os.O_TEXT`; for binary, it should be
:const:`os.O_BINARY`. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
a9dd50ca-7eb8-4455-934b-0460970b6329 | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,532 | supabase-export-v2 | 7b5b6045e84c1821 | .. function:: CrtSetReportFile(type, file)
After you use :func:`CrtSetReportMode` to specify :const:`CRTDBG_MODE_FILE`,
you can specify the file handle to receive the message text. *type* must be
one of the :const:`!CRT_\*` constants listed below. *file* should be the file
handle your want specified. Only available ... | trusted_official_docs | CPython Docs | .. function:: CrtSetReportFile(type, file)
After you use :func:`CrtSetReportMode` to specify :const:`CRTDBG_MODE_FILE`,
you can specify the file handle to receive the message text. *type* must be
one of the :const:`!CRT_\*` constants listed below. *file* should be the file
handle your want specified. Only available ... | .. function:: CrtSetReportFile(type, file)
After you use :func:`CrtSetReportMode` to specify :const:`CRTDBG_MODE_FILE`,
you can specify the file handle to receive the message text. *type* must be
one of the :const:`!CRT_\*` constants listed below. *file* should be the file
handle your want specified. Only available ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
b37de099-9b17-4477-86b3-1cba6cd862c8 | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,474 | supabase-export-v2 | 3e75263d6441dbbe | --------------
These functions provide access to some useful capabilities on Windows platforms. Some higher-level modules use these functions to build the Windows
implementations of their services. For example, the :mod:`getpass` module uses
this in the implementation of the :func:`getpass` function. | trusted_official_docs | CPython Docs | --------------
These functions provide access to some useful capabilities on Windows platforms. Some higher-level modules use these functions to build the Windows
implementations of their services. For example, the :mod:`getpass` module uses
this in the implementation of the :func:`getpass` function. | --------------
These functions provide access to some useful capabilities on Windows platforms. Some higher-level modules use these functions to build the Windows
implementations of their services. For example, the :mod:`getpass` module uses
this in the implementation of the :func:`getpass` function. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
b5b1523c-58e6-4482-9608-cafbd03e0a5c | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,482 | supabase-export-v2 | cf656a072f30000e | regions in a file may be locked at the same time, but may not overlap. Adjacent regions are not merged; they must be unlocked individually.
.. audit-event:: msvcrt.locking fd,mode,nbytes msvcrt.locking | trusted_official_docs | CPython Docs | regions in a file may be locked at the same time, but may not overlap. Adjacent regions are not merged; they must be unlocked individually.
.. audit-event:: msvcrt.locking fd,mode,nbytes msvcrt.locking | regions in a file may be locked at the same time, but may not overlap. Adjacent regions are not merged; they must be unlocked individually.
.. audit-event:: msvcrt.locking fd,mode,nbytes msvcrt.locking | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c98da542-b67f-4548-a2f9-06b94746d254 | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,484 | supabase-export-v2 | 4934d94439bc02fe | .. data:: LK_LOCK LK_RLCK
Locks the specified bytes. If the bytes cannot be locked, the program
immediately tries again after 1 second. If, after 10 attempts, the bytes cannot
be locked, :exc:`OSError` is raised. | trusted_official_docs | CPython Docs | .. data:: LK_LOCK LK_RLCK
Locks the specified bytes. If the bytes cannot be locked, the program
immediately tries again after 1 second. If, after 10 attempts, the bytes cannot
be locked, :exc:`OSError` is raised. | .. data:: LK_LOCK LK_RLCK
Locks the specified bytes. If the bytes cannot be locked, the program
immediately tries again after 1 second. If, after 10 attempts, the bytes cannot
be locked, :exc:`OSError` is raised. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c9eeaf9d-7c1a-4fc7-b662-e1464cdec659 | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,475 | supabase-export-v2 | f0e0097f9393e51b | use these functions to build the Windows implementations of their services. For example, the :mod:`getpass` module uses this in the implementation of the :func:`getpass` function.
Further documentation on these functions can be found in the Platform API
documentation. | trusted_official_docs | CPython Docs | use these functions to build the Windows implementations of their services. For example, the :mod:`getpass` module uses this in the implementation of the :func:`getpass` function.
Further documentation on these functions can be found in the Platform API
documentation. | use these functions to build the Windows implementations of their services. For example, the :mod:`getpass` module uses this in the implementation of the :func:`getpass` function.
Further documentation on these functions can be found in the Platform API
documentation. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
d9bbadf6-cd77-47e3-adfa-ca6fa9c6f02f | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,492 | supabase-export-v2 | 1833236f757d8aee | .. function:: open_osfhandle(handle, flags)
Create a C runtime file descriptor from the file handle *handle*. The *flags*
parameter should be a bitwise OR of :const:`os.O_APPEND`,
:const:`os.O_RDONLY`, :const:`os.O_TEXT` and :const:`os.O_NOINHERIT`. The returned file descriptor may be used as a parameter
to :func:`o... | trusted_official_docs | CPython Docs | .. function:: open_osfhandle(handle, flags)
Create a C runtime file descriptor from the file handle *handle*. The *flags*
parameter should be a bitwise OR of :const:`os.O_APPEND`,
:const:`os.O_RDONLY`, :const:`os.O_TEXT` and :const:`os.O_NOINHERIT`. The returned file descriptor may be used as a parameter
to :func:`o... | .. function:: open_osfhandle(handle, flags)
Create a C runtime file descriptor from the file handle *handle*. The *flags*
parameter should be a bitwise OR of :const:`os.O_APPEND`,
:const:`os.O_RDONLY`, :const:`os.O_TEXT` and :const:`os.O_NOINHERIT`. The returned file descriptor may be used as a parameter
to :func:`o... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
e01d4d41-7ab4-4fb8-9f5e-230dc9c2622e | CPython Docs | file://datasets/cpython/Doc/library/msvcrt.rst | unknown | 9e12da1d-b2dd-4d55-8637-0d1dfb50098b | 21,476 | supabase-export-v2 | cb0b478a4cb555ac | Further documentation on these functions can be found in the Platform API documentation.
The module implements both the normal and wide char variants of the console I/O
api. The normal API deals only with ASCII characters and is of limited use
for internationalized applications. The wide char API should be used where
e... | trusted_official_docs | CPython Docs | Further documentation on these functions can be found in the Platform API documentation.
The module implements both the normal and wide char variants of the console I/O
api. The normal API deals only with ASCII characters and is of limited use
for internationalized applications. The wide char API should be used where
e... | Further documentation on these functions can be found in the Platform API documentation.
The module implements both the normal and wide char variants of the console I/O
api. The normal API deals only with ASCII characters and is of limited use
for internationalized applications. The wide char API should be used where
e... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
25059e76-2298-41bf-a74e-518dc32481a7 | CPython Docs | file://datasets/cpython/Doc/library/modulefinder.rst | unknown | b71c1958-0e5a-4e40-98e3-43b122dbc966 | 21,561 | supabase-export-v2 | cb4df28bc47f5326 | .. class:: ModuleFinder(path=None, debug=0, excludes=[], replace_paths=[])
This class provides :meth:`run_script` and :meth:`report` methods to determine
the set of modules imported by a script. *path* can be a list of directories to
search for modules; if not specified, ``sys.path`` is used. *debug* sets the
debugg... | trusted_official_docs | CPython Docs | .. class:: ModuleFinder(path=None, debug=0, excludes=[], replace_paths=[])
This class provides :meth:`run_script` and :meth:`report` methods to determine
the set of modules imported by a script. *path* can be a list of directories to
search for modules; if not specified, ``sys.path`` is used. *debug* sets the
debugg... | .. class:: ModuleFinder(path=None, debug=0, excludes=[], replace_paths=[])
This class provides :meth:`run_script` and :meth:`report` methods to determine
the set of modules imported by a script. *path* can be a list of directories to
search for modules; if not specified, ``sys.path`` is used. *debug* sets the
debugg... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
2ad99042-dc1b-496e-872a-d5c3f183bd43 | CPython Docs | file://datasets/cpython/Doc/library/modulefinder.rst | unknown | b71c1958-0e5a-4e40-98e3-43b122dbc966 | 21,555 | supabase-export-v2 | b4854812bf0d81fd | --------------
This module provides a :class:`ModuleFinder` class that can be used to determine
the set of modules imported by a script. ``modulefinder.py`` can also be run as
a script, giving the filename of a Python script as its argument, after which a
report of the imported modules will be printed. | trusted_official_docs | CPython Docs | --------------
This module provides a :class:`ModuleFinder` class that can be used to determine
the set of modules imported by a script. ``modulefinder.py`` can also be run as
a script, giving the filename of a Python script as its argument, after which a
report of the imported modules will be printed. | --------------
This module provides a :class:`ModuleFinder` class that can be used to determine
the set of modules imported by a script. ``modulefinder.py`` can also be run as
a script, giving the filename of a Python script as its argument, after which a
report of the imported modules will be printed. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
51ae1a4d-dc36-4fec-8551-d15914cef0ca | CPython Docs | file://datasets/cpython/Doc/library/modulefinder.rst | unknown | b71c1958-0e5a-4e40-98e3-43b122dbc966 | 21,563 | supabase-export-v2 | 0df36b2faec73b22 | .. method:: report()
Print a report to standard output that lists the modules imported by the
script and their paths, as well as modules that are missing or seem to be
missing. | trusted_official_docs | CPython Docs | .. method:: report()
Print a report to standard output that lists the modules imported by the
script and their paths, as well as modules that are missing or seem to be
missing. | .. method:: report()
Print a report to standard output that lists the modules imported by the
script and their paths, as well as modules that are missing or seem to be
missing. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
da14f1da-a557-453c-aabf-a0cd756ed7ea | CPython Docs | file://datasets/cpython/Doc/library/modulefinder.rst | unknown | b71c1958-0e5a-4e40-98e3-43b122dbc966 | 21,580 | supabase-export-v2 | 893b7bf1a2a59b29 | Sample output (may vary depending on the architecture)::
Loaded modules:
_types:
copyreg: _inverted_registry,_slotnames,__all__
re._compiler: isstring,_sre,_optimize_unicode
_sre:
re._constants: REPEAT_ONE,makedict,AT_END_LINE
sys:
re: __module__,finditer,_expand
itertools:
__main__: re,itertools,baconhameggs
... | trusted_official_docs | CPython Docs | Sample output (may vary depending on the architecture)::
Loaded modules:
_types:
copyreg: _inverted_registry,_slotnames,__all__
re._compiler: isstring,_sre,_optimize_unicode
_sre:
re._constants: REPEAT_ONE,makedict,AT_END_LINE
sys:
re: __module__,finditer,_expand
itertools:
__main__: re,itertools,baconhameggs
... | Sample output (may vary depending on the architecture)::
Loaded modules:
_types:
copyreg: _inverted_registry,_slotnames,__all__
re._compiler: isstring,_sre,_optimize_unicode
_sre:
re._constants: REPEAT_ONE,makedict,AT_END_LINE
sys:
re: __module__,finditer,_expand
itertools:
__main__: re,itertools,baconhameggs
... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
00ab8861-5bfa-44d9-a341-ca9e571bccc5 | CPython Docs | file://datasets/cpython/Doc/library/asyncio-extending.rst | unknown | 340e90ee-d67d-4ac7-a5fe-e5939c230cfe | 21,593 | supabase-export-v2 | 228dc33afe620ef9 | However, third-party *event loops* may *reuse* built-in future and task implementations for the sake of getting a complex and highly optimized code for free.
For this purpose the following, *private* constructors are listed: | trusted_official_docs | CPython Docs | However, third-party *event loops* may *reuse* built-in future and task implementations for the sake of getting a complex and highly optimized code for free.
For this purpose the following, *private* constructors are listed: | However, third-party *event loops* may *reuse* built-in future and task implementations for the sake of getting a complex and highly optimized code for free.
For this purpose the following, *private* constructors are listed: | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
b8593013-dddf-46f0-ba99-8797e2b7a629 | CPython Docs | file://datasets/cpython/Doc/library/asyncio-extending.rst | unknown | 340e90ee-d67d-4ac7-a5fe-e5939c230cfe | 21,592 | supabase-export-v2 | 9c4285495acdc687 | :class:`asyncio.Future` and :class:`asyncio.Task` should be never created directly, please use corresponding :meth:`loop.create_future` and :meth:`loop.create_task`, or :func:`asyncio.create_task` factories instead.
However, third-party *event loops* may *reuse* built-in future and task implementations
for the sake of ... | trusted_official_docs | CPython Docs | :class:`asyncio.Future` and :class:`asyncio.Task` should be never created directly, please use corresponding :meth:`loop.create_future` and :meth:`loop.create_task`, or :func:`asyncio.create_task` factories instead.
However, third-party *event loops* may *reuse* built-in future and task implementations
for the sake of ... | :class:`asyncio.Future` and :class:`asyncio.Task` should be never created directly, please use corresponding :meth:`loop.create_future` and :meth:`loop.create_task`, or :func:`asyncio.create_task` factories instead.
However, third-party *event loops* may *reuse* built-in future and task implementations
for the sake of ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c1253b9f-72fb-4a5b-a30e-c80abfc67522 | CPython Docs | file://datasets/cpython/Doc/library/asyncio-extending.rst | unknown | 340e90ee-d67d-4ac7-a5fe-e5939c230cfe | 21,589 | supabase-export-v2 | a4077453ba3b1e56 | In turn, the successor should implement a bunch of *private* methods declared but not implemented in :class:`asyncio.BaseEventLoop`.
For example, ``loop.create_connection()`` checks arguments, resolves DNS addresses, and
calls ``loop._make_socket_transport()`` that should be implemented by inherited class. The ``_make_... | trusted_official_docs | CPython Docs | In turn, the successor should implement a bunch of *private* methods declared but not implemented in :class:`asyncio.BaseEventLoop`.
For example, ``loop.create_connection()`` checks arguments, resolves DNS addresses, and
calls ``loop._make_socket_transport()`` that should be implemented by inherited class. The ``_make_... | In turn, the successor should implement a bunch of *private* methods declared but not implemented in :class:`asyncio.BaseEventLoop`.
For example, ``loop.create_connection()`` checks arguments, resolves DNS addresses, and
calls ``loop._make_socket_transport()`` that should be implemented by inherited class. The ``_make_... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ceae72a5-fc97-4f75-bdfd-5e178ffe9259 | CPython Docs | file://datasets/cpython/Doc/library/asyncio-extending.rst | unknown | 340e90ee-d67d-4ac7-a5fe-e5939c230cfe | 21,590 | supabase-export-v2 | 87267e6865cffdd8 | DNS addresses, and calls ``loop._make_socket_transport()`` that should be implemented by inherited class. The ``_make_socket_transport()`` method is not documented and is considered as an *internal* API.
Future and Task private constructors
==================================== | trusted_official_docs | CPython Docs | DNS addresses, and calls ``loop._make_socket_transport()`` that should be implemented by inherited class. The ``_make_socket_transport()`` method is not documented and is considered as an *internal* API.
Future and Task private constructors
==================================== | DNS addresses, and calls ``loop._make_socket_transport()`` that should be implemented by inherited class. The ``_make_socket_transport()`` method is not documented and is considered as an *internal* API.
Future and Task private constructors
==================================== | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
e631b2de-f91f-41da-b54e-6a553d59d7e2 | CPython Docs | file://datasets/cpython/Doc/library/asyncio-extending.rst | unknown | 340e90ee-d67d-4ac7-a5fe-e5939c230cfe | 21,588 | supabase-export-v2 | a724b2f7f9dd92c2 | A loop can get many common methods implementation for free by inheriting from :class:`asyncio.BaseEventLoop`.
In turn, the successor should implement a bunch of *private* methods declared but not
implemented in :class:`asyncio.BaseEventLoop`. | trusted_official_docs | CPython Docs | A loop can get many common methods implementation for free by inheriting from :class:`asyncio.BaseEventLoop`.
In turn, the successor should implement a bunch of *private* methods declared but not
implemented in :class:`asyncio.BaseEventLoop`. | A loop can get many common methods implementation for free by inheriting from :class:`asyncio.BaseEventLoop`.
In turn, the successor should implement a bunch of *private* methods declared but not
implemented in :class:`asyncio.BaseEventLoop`. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
09172621-ce26-4e61-a3b8-0c94ccbbc962 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,657 | supabase-export-v2 | 3af9c7877d9d17d7 | .. method:: InteractiveConsole.interact(banner=None, exitmsg=None)
Closely emulate the interactive Python console. The optional *banner* argument
specify the banner to print before the first interaction; by default it prints a
banner similar to the one printed by the standard Python interpreter, followed
by the clas... | trusted_official_docs | CPython Docs | .. method:: InteractiveConsole.interact(banner=None, exitmsg=None)
Closely emulate the interactive Python console. The optional *banner* argument
specify the banner to print before the first interaction; by default it prints a
banner similar to the one printed by the standard Python interpreter, followed
by the clas... | .. method:: InteractiveConsole.interact(banner=None, exitmsg=None)
Closely emulate the interactive Python console. The optional *banner* argument
specify the banner to print before the first interaction; by default it prints a
banner similar to the one printed by the standard Python interpreter, followed
by the clas... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
122a5f81-7971-4592-87e7-ea6712b924e4 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,666 | supabase-export-v2 | bf116034bbe27e4e | .. method:: InteractiveConsole.raw_input(prompt="")
Write a prompt and read a line. The returned line does not include the trailing
newline. When the user enters the EOF key sequence, :exc:`EOFError` is raised. The base implementation reads from ``sys.stdin``; a subclass may replace this
with a different implementati... | trusted_official_docs | CPython Docs | .. method:: InteractiveConsole.raw_input(prompt="")
Write a prompt and read a line. The returned line does not include the trailing
newline. When the user enters the EOF key sequence, :exc:`EOFError` is raised. The base implementation reads from ``sys.stdin``; a subclass may replace this
with a different implementati... | .. method:: InteractiveConsole.raw_input(prompt="")
Write a prompt and read a line. The returned line does not include the trailing
newline. When the user enters the EOF key sequence, :exc:`EOFError` is raised. The base implementation reads from ``sys.stdin``; a subclass may replace this
with a different implementati... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
137b0a25-2e71-4a71-a485-f91dbb0a133e | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,620 | supabase-export-v2 | 1e22577a76dab916 | --------------
The ``code`` module provides facilities to implement read-eval-print loops in
Python. Two classes and convenience functions are included which can be used to
build applications which provide an interactive interpreter prompt. | trusted_official_docs | CPython Docs | --------------
The ``code`` module provides facilities to implement read-eval-print loops in
Python. Two classes and convenience functions are included which can be used to
build applications which provide an interactive interpreter prompt. | --------------
The ``code`` module provides facilities to implement read-eval-print loops in
Python. Two classes and convenience functions are included which can be used to
build applications which provide an interactive interpreter prompt. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
19defd4a-a655-40f9-bc3e-e8ccc505ad4a | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,634 | supabase-export-v2 | 866b3c75ee4587f8 | from which source was read, defaulting to ``'<input>'``; and *symbol* is the optional grammar start symbol, which should be ``'single'`` (the default), ``'eval'`` or ``'exec'``.
Returns a code object (the same as ``compile(source, filename, symbol)``) if the
command is complete and valid; ``None`` if the command is in... | trusted_official_docs | CPython Docs | from which source was read, defaulting to ``'<input>'``; and *symbol* is the optional grammar start symbol, which should be ``'single'`` (the default), ``'eval'`` or ``'exec'``.
Returns a code object (the same as ``compile(source, filename, symbol)``) if the
command is complete and valid; ``None`` if the command is in... | from which source was read, defaulting to ``'<input>'``; and *symbol* is the optional grammar start symbol, which should be ``'single'`` (the default), ``'eval'`` or ``'exec'``.
Returns a code object (the same as ``compile(source, filename, symbol)``) if the
command is complete and valid; ``None`` if the command is in... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
1e91f940-26aa-45b9-945e-5f57e59c2cee | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,628 | supabase-export-v2 | ddf734d5d030c0a7 | .. function:: interact(banner=None, readfunc=None, local=None, exitmsg=None, local_exit=False)
Convenience function to run a read-eval-print loop. This creates a new
instance of :class:`InteractiveConsole` and sets *readfunc* to be used as
the :meth:`InteractiveConsole.raw_input` method, if provided. If *local* is
p... | trusted_official_docs | CPython Docs | .. function:: interact(banner=None, readfunc=None, local=None, exitmsg=None, local_exit=False)
Convenience function to run a read-eval-print loop. This creates a new
instance of :class:`InteractiveConsole` and sets *readfunc* to be used as
the :meth:`InteractiveConsole.raw_input` method, if provided. If *local* is
p... | .. function:: interact(banner=None, readfunc=None, local=None, exitmsg=None, local_exit=False)
Convenience function to run a read-eval-print loop. This creates a new
instance of :class:`InteractiveConsole` and sets *readfunc* to be used as
the :meth:`InteractiveConsole.raw_input` method, if provided. If *local* is
p... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
27cb5062-bc77-4d2e-912f-bf713abad3de | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,632 | supabase-export-v2 | 04152d258e7dd756 | .. function:: compile_command(source, filename="<input>", symbol="single")
This function is useful for programs that want to emulate Python's interpreter
main loop (a.k.a. the read-eval-print loop). The tricky part is to determine
when the user has entered an incomplete command that can be completed by
entering more... | trusted_official_docs | CPython Docs | .. function:: compile_command(source, filename="<input>", symbol="single")
This function is useful for programs that want to emulate Python's interpreter
main loop (a.k.a. the read-eval-print loop). The tricky part is to determine
when the user has entered an incomplete command that can be completed by
entering more... | .. function:: compile_command(source, filename="<input>", symbol="single")
This function is useful for programs that want to emulate Python's interpreter
main loop (a.k.a. the read-eval-print loop). The tricky part is to determine
when the user has entered an incomplete command that can be completed by
entering more... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
3a8af935-f25c-44fe-8dcb-414224836eb5 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,633 | supabase-export-v2 | 8400223b1877f4e9 | text (as opposed to a complete command or a syntax error). This function *almost* always makes the same decision as the real interpreter main loop.
*source* is the source string; *filename* is the optional filename from which
source was read, defaulting to ``'<input>'``; and *symbol* is the optional
grammar start sym... | trusted_official_docs | CPython Docs | text (as opposed to a complete command or a syntax error). This function *almost* always makes the same decision as the real interpreter main loop.
*source* is the source string; *filename* is the optional filename from which
source was read, defaulting to ``'<input>'``; and *symbol* is the optional
grammar start sym... | text (as opposed to a complete command or a syntax error). This function *almost* always makes the same decision as the real interpreter main loop.
*source* is the source string; *filename* is the optional filename from which
source was read, defaulting to ``'<input>'``; and *symbol* is the optional
grammar start sym... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
45ba0a10-145b-4906-b87b-97a55ca9d3e4 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,622 | supabase-export-v2 | 755ec78a5dff185a | .. class:: InteractiveInterpreter(locals=None)
This class deals with parsing and interpreter state (the user's namespace); it
does not deal with input buffering or prompting or input file naming (the
filename is always passed in explicitly). The optional *locals* argument
specifies a mapping to use as the namespace ... | trusted_official_docs | CPython Docs | .. class:: InteractiveInterpreter(locals=None)
This class deals with parsing and interpreter state (the user's namespace); it
does not deal with input buffering or prompting or input file naming (the
filename is always passed in explicitly). The optional *locals* argument
specifies a mapping to use as the namespace ... | .. class:: InteractiveInterpreter(locals=None)
This class deals with parsing and interpreter state (the user's namespace); it
does not deal with input buffering or prompting or input file naming (the
filename is always passed in explicitly). The optional *locals* argument
specifies a mapping to use as the namespace ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
4be81e25-d118-4d8e-89c2-4018f7bc1df6 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,626 | supabase-export-v2 | aefad9b14b732641 | ``sys.ps2``, and input buffering. If *local_exit* is true, ``exit()`` and ``quit()`` in the console will not raise :exc:`SystemExit`, but instead return to the calling code.
.. versionchanged:: 3.13
Added *local_exit* parameter. | trusted_official_docs | CPython Docs | ``sys.ps2``, and input buffering. If *local_exit* is true, ``exit()`` and ``quit()`` in the console will not raise :exc:`SystemExit`, but instead return to the calling code.
.. versionchanged:: 3.13
Added *local_exit* parameter. | ``sys.ps2``, and input buffering. If *local_exit* is true, ``exit()`` and ``quit()`` in the console will not raise :exc:`SystemExit`, but instead return to the calling code.
.. versionchanged:: 3.13
Added *local_exit* parameter. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
5307986d-288d-4c96-b240-9cf0a47b9dac | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,659 | supabase-export-v2 | 74dc06ecf15a04f3 | message printed when exiting. Pass the empty string to suppress the exit message. If *exitmsg* is not given or ``None``, a default message is printed.
.. versionchanged:: 3.4
To suppress printing any banner, pass an empty string. | trusted_official_docs | CPython Docs | message printed when exiting. Pass the empty string to suppress the exit message. If *exitmsg* is not given or ``None``, a default message is printed.
.. versionchanged:: 3.4
To suppress printing any banner, pass an empty string. | message printed when exiting. Pass the empty string to suppress the exit message. If *exitmsg* is not given or ``None``, a default message is printed.
.. versionchanged:: 3.4
To suppress printing any banner, pass an empty string. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
6527f612-6d6d-4de5-8fd1-0270c42da2e6 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,650 | supabase-export-v2 | 1fc876bca1b5d58f | that just occurred. We remove the first stack item because it is within the interpreter object implementation. The output is written by the :meth:`write` method.
.. versionchanged:: 3.5 The full chained traceback is displayed instead
of just the primary traceback. | trusted_official_docs | CPython Docs | that just occurred. We remove the first stack item because it is within the interpreter object implementation. The output is written by the :meth:`write` method.
.. versionchanged:: 3.5 The full chained traceback is displayed instead
of just the primary traceback. | that just occurred. We remove the first stack item because it is within the interpreter object implementation. The output is written by the :meth:`write` method.
.. versionchanged:: 3.5 The full chained traceback is displayed instead
of just the primary traceback. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
7271a522-e444-4af1-b1f6-38937cc05a0f | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,658 | supabase-export-v2 | d45b6125294d876e | by the class name of the console object in parentheses (so as not to confuse this with the real interpreter -- since it's so close!).
The optional *exitmsg* argument specifies an exit message printed when exiting. Pass the empty string to suppress the exit message. If *exitmsg* is not given or
``None``, a default mess... | trusted_official_docs | CPython Docs | by the class name of the console object in parentheses (so as not to confuse this with the real interpreter -- since it's so close!).
The optional *exitmsg* argument specifies an exit message printed when exiting. Pass the empty string to suppress the exit message. If *exitmsg* is not given or
``None``, a default mess... | by the class name of the console object in parentheses (so as not to confuse this with the real interpreter -- since it's so close!).
The optional *exitmsg* argument specifies an exit message printed when exiting. Pass the empty string to suppress the exit message. If *exitmsg* is not given or
``None``, a default mess... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
76b07cff-ec83-4863-8e03-c6db79c6af37 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,645 | supabase-export-v2 | 81a5bcc60258a959 | a code object. When an exception occurs, :meth:`showtraceback` is called to display a traceback. All exceptions are caught except :exc:`SystemExit`, which is allowed to propagate.
A note about :exc:`KeyboardInterrupt`: this exception may occur elsewhere in
this code, and may not always be caught. The caller should be ... | trusted_official_docs | CPython Docs | a code object. When an exception occurs, :meth:`showtraceback` is called to display a traceback. All exceptions are caught except :exc:`SystemExit`, which is allowed to propagate.
A note about :exc:`KeyboardInterrupt`: this exception may occur elsewhere in
this code, and may not always be caught. The caller should be ... | a code object. When an exception occurs, :meth:`showtraceback` is called to display a traceback. All exceptions are caught except :exc:`SystemExit`, which is allowed to propagate.
A note about :exc:`KeyboardInterrupt`: this exception may occur elsewhere in
this code, and may not always be caught. The caller should be ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
8fc56d84-046d-42c9-ae9e-44238e04be0b | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,639 | supabase-export-v2 | eb8cd900fc767fa5 | interpreter. Arguments are the same as for :func:`compile_command`; the default for *filename* is ``'<input>'``, and for *symbol* is ``'single'``. One of several things can happen:
* The input is incorrect; :func:`compile_command` raised an exception
(:exc:`SyntaxError` or :exc:`OverflowError`). A syntax traceback wil... | trusted_official_docs | CPython Docs | interpreter. Arguments are the same as for :func:`compile_command`; the default for *filename* is ``'<input>'``, and for *symbol* is ``'single'``. One of several things can happen:
* The input is incorrect; :func:`compile_command` raised an exception
(:exc:`SyntaxError` or :exc:`OverflowError`). A syntax traceback wil... | interpreter. Arguments are the same as for :func:`compile_command`; the default for *filename* is ``'<input>'``, and for *symbol* is ``'single'``. One of several things can happen:
* The input is incorrect; :func:`compile_command` raised an exception
(:exc:`SyntaxError` or :exc:`OverflowError`). A syntax traceback wil... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
8fe3f865-6049-418f-9044-2596661d562d | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,649 | supabase-export-v2 | 3e604a559d590d6e | .. method:: InteractiveInterpreter.showtraceback()
Display the exception that just occurred. We remove the first stack item
because it is within the interpreter object implementation. The output is
written by the :meth:`write` method. | trusted_official_docs | CPython Docs | .. method:: InteractiveInterpreter.showtraceback()
Display the exception that just occurred. We remove the first stack item
because it is within the interpreter object implementation. The output is
written by the :meth:`write` method. | .. method:: InteractiveInterpreter.showtraceback()
Display the exception that just occurred. We remove the first stack item
because it is within the interpreter object implementation. The output is
written by the :meth:`write` method. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
9ffefd9b-148f-4680-9d9e-19dd241247e0 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,624 | supabase-export-v2 | 7d893fbb60d80658 | under an :class:`!InteractiveInterpreter` instance will belong to the namespace specified by *locals*. They are only pickleable if *locals* is the namespace of an existing module.
.. class:: InteractiveConsole(locals=None, filename="<console>", *, local_exit=False) | trusted_official_docs | CPython Docs | under an :class:`!InteractiveInterpreter` instance will belong to the namespace specified by *locals*. They are only pickleable if *locals* is the namespace of an existing module.
.. class:: InteractiveConsole(locals=None, filename="<console>", *, local_exit=False) | under an :class:`!InteractiveInterpreter` instance will belong to the namespace specified by *locals*. They are only pickleable if *locals* is the namespace of an existing module.
.. class:: InteractiveConsole(locals=None, filename="<console>", *, local_exit=False) | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ac32803e-85ec-46c1-a171-8f9f5e71a9f0 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,640 | supabase-export-v2 | 6bd90ca39f693b6e | The input is incorrect; :func:`compile_command` raised an exception (:exc:`SyntaxError` or :exc:`OverflowError`). A syntax traceback will be printed by calling the :meth:`showsyntaxerror` method. :meth:`runsource` returns ``False``.
* The input is incomplete, and more input is required; :func:`compile_command`
returne... | trusted_official_docs | CPython Docs | The input is incorrect; :func:`compile_command` raised an exception (:exc:`SyntaxError` or :exc:`OverflowError`). A syntax traceback will be printed by calling the :meth:`showsyntaxerror` method. :meth:`runsource` returns ``False``.
* The input is incomplete, and more input is required; :func:`compile_command`
returne... | The input is incorrect; :func:`compile_command` raised an exception (:exc:`SyntaxError` or :exc:`OverflowError`). A syntax traceback will be printed by calling the :meth:`showsyntaxerror` method. :meth:`runsource` returns ``False``.
* The input is incomplete, and more input is required; :func:`compile_command`
returne... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
b074b7eb-f5f7-47ed-9662-a063018d1a9d | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,629 | supabase-export-v2 | 5a0a6532ce91eda2 | is then run with *banner* and *exitmsg* passed as the banner and exit message to use, if provided. The console object is discarded after use.
.. versionchanged:: 3.6
Added *exitmsg* parameter. | trusted_official_docs | CPython Docs | is then run with *banner* and *exitmsg* passed as the banner and exit message to use, if provided. The console object is discarded after use.
.. versionchanged:: 3.6
Added *exitmsg* parameter. | is then run with *banner* and *exitmsg* passed as the banner and exit message to use, if provided. The console object is discarded after use.
.. versionchanged:: 3.6
Added *exitmsg* parameter. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
be8514a9-25b2-4f54-846e-9c9d99c9a5c0 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,638 | supabase-export-v2 | 92d77f165fd9fbe1 | .. method:: InteractiveInterpreter.runsource(source, filename="<input>", symbol="single")
Compile and run some source in the interpreter. Arguments are the same as for
:func:`compile_command`; the default for *filename* is ``'<input>'``, and for
*symbol* is ``'single'``. One of several things can happen: | trusted_official_docs | CPython Docs | .. method:: InteractiveInterpreter.runsource(source, filename="<input>", symbol="single")
Compile and run some source in the interpreter. Arguments are the same as for
:func:`compile_command`; the default for *filename* is ``'<input>'``, and for
*symbol* is ``'single'``. One of several things can happen: | .. method:: InteractiveInterpreter.runsource(source, filename="<input>", symbol="single")
Compile and run some source in the interpreter. Arguments are the same as for
:func:`compile_command`; the default for *filename* is ``'<input>'``, and for
*symbol* is ``'single'``. One of several things can happen: | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c177e837-4ffb-42e9-ba90-d15674fc5d4b | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,641 | supabase-export-v2 | 0a4ecf061df471cb | * The input is incomplete, and more input is required; :func:`compile_command` returned ``None``. :meth:`runsource` returns ``True``.
* The input is complete; :func:`compile_command` returned a code object. The
code is executed by calling the :meth:`runcode` (which also handles run-time
exceptions, except for :exc:`S... | trusted_official_docs | CPython Docs | * The input is incomplete, and more input is required; :func:`compile_command` returned ``None``. :meth:`runsource` returns ``True``.
* The input is complete; :func:`compile_command` returned a code object. The
code is executed by calling the :meth:`runcode` (which also handles run-time
exceptions, except for :exc:`S... | * The input is incomplete, and more input is required; :func:`compile_command` returned ``None``. :meth:`runsource` returns ``True``.
* The input is complete; :func:`compile_command` returned a code object. The
code is executed by calling the :meth:`runcode` (which also handles run-time
exceptions, except for :exc:`S... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
c9719821-0ba0-4f60-b445-9aa30be31738 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,625 | supabase-export-v2 | 203b59a44c1fc4f2 | .. class:: InteractiveConsole(locals=None, filename="<console>", *, local_exit=False)
Closely emulate the behavior of the interactive Python interpreter. This class
builds on :class:`InteractiveInterpreter` and adds prompting using the familiar
``sys.ps1`` and ``sys.ps2``, and input buffering. If *local_exit* is true... | trusted_official_docs | CPython Docs | .. class:: InteractiveConsole(locals=None, filename="<console>", *, local_exit=False)
Closely emulate the behavior of the interactive Python interpreter. This class
builds on :class:`InteractiveInterpreter` and adds prompting using the familiar
``sys.ps1`` and ``sys.ps2``, and input buffering. If *local_exit* is true... | .. class:: InteractiveConsole(locals=None, filename="<console>", *, local_exit=False)
Closely emulate the behavior of the interactive Python interpreter. This class
builds on :class:`InteractiveInterpreter` and adds prompting using the familiar
``sys.ps1`` and ``sys.ps2``, and input buffering. If *local_exit* is true... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
cb7d173c-9cd7-4029-9829-8732e95f7e16 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,662 | supabase-export-v2 | a53cf6cd0e2edb38 | .. method:: InteractiveConsole.push(line)
Push a line of source text to the interpreter. The line should not have a
trailing newline; it may have internal newlines. The line is appended to a
buffer and the interpreter's :meth:`~InteractiveInterpreter.runsource` method is called with the
concatenated contents of the ... | trusted_official_docs | CPython Docs | .. method:: InteractiveConsole.push(line)
Push a line of source text to the interpreter. The line should not have a
trailing newline; it may have internal newlines. The line is appended to a
buffer and the interpreter's :meth:`~InteractiveInterpreter.runsource` method is called with the
concatenated contents of the ... | .. method:: InteractiveConsole.push(line)
Push a line of source text to the interpreter. The line should not have a
trailing newline; it may have internal newlines. The line is appended to a
buffer and the interpreter's :meth:`~InteractiveInterpreter.runsource` method is called with the
concatenated contents of the ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
eb0b841d-2cbf-4f78-8ad8-4d7ee567eb9b | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,642 | supabase-export-v2 | b820513cb833ad52 | complete; :func:`compile_command` returned a code object. The code is executed by calling the :meth:`runcode` (which also handles run-time exceptions, except for :exc:`SystemExit`). :meth:`runsource` returns ``False``.
The return value can be used to decide whether to use ``sys.ps1`` or ``sys.ps2``
to prompt the next ... | trusted_official_docs | CPython Docs | complete; :func:`compile_command` returned a code object. The code is executed by calling the :meth:`runcode` (which also handles run-time exceptions, except for :exc:`SystemExit`). :meth:`runsource` returns ``False``.
The return value can be used to decide whether to use ``sys.ps1`` or ``sys.ps2``
to prompt the next ... | complete; :func:`compile_command` returned a code object. The code is executed by calling the :meth:`runcode` (which also handles run-time exceptions, except for :exc:`SystemExit`). :meth:`runsource` returns ``False``.
The return value can be used to decide whether to use ``sys.ps1`` or ``sys.ps2``
to prompt the next ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
fae9d686-3fcc-4a2e-8aba-7ee1331d1375 | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,623 | supabase-export-v2 | a477cb9e891556a3 | in which code will be executed; it defaults to a newly created dictionary with key ``'__name__'`` set to ``'__console__'`` and key ``'__doc__'`` set to ``None``.
Note that functions and classes objects created under an
:class:`!InteractiveInterpreter` instance will belong to the namespace
specified by *locals*. They ... | trusted_official_docs | CPython Docs | in which code will be executed; it defaults to a newly created dictionary with key ``'__name__'`` set to ``'__console__'`` and key ``'__doc__'`` set to ``None``.
Note that functions and classes objects created under an
:class:`!InteractiveInterpreter` instance will belong to the namespace
specified by *locals*. They ... | in which code will be executed; it defaults to a newly created dictionary with key ``'__name__'`` set to ``'__console__'`` and key ``'__doc__'`` set to ``None``.
Note that functions and classes objects created under an
:class:`!InteractiveInterpreter` instance will belong to the namespace
specified by *locals*. They ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ffde8778-fe0c-41b2-a4fa-f99f424f0d2a | CPython Docs | file://datasets/cpython/Doc/library/code.rst | unknown | e8a52b2f-3dd9-45d4-8a93-8b86889b1c29 | 21,647 | supabase-export-v2 | 93d80b0904b8422f | .. method:: InteractiveInterpreter.showsyntaxerror(filename=None)
Display the syntax error that just occurred. This does not display a stack
trace because there isn't one for syntax errors. If *filename* is given, it is
stuffed into the exception instead of the default filename provided by Python's
parser, because i... | trusted_official_docs | CPython Docs | .. method:: InteractiveInterpreter.showsyntaxerror(filename=None)
Display the syntax error that just occurred. This does not display a stack
trace because there isn't one for syntax errors. If *filename* is given, it is
stuffed into the exception instead of the default filename provided by Python's
parser, because i... | .. method:: InteractiveInterpreter.showsyntaxerror(filename=None)
Display the syntax error that just occurred. This does not display a stack
trace because there isn't one for syntax errors. If *filename* is given, it is
stuffed into the exception instead of the default filename provided by Python's
parser, because i... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
00d2d712-4ac1-4925-a473-1e6883da5fb6 | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,682 | supabase-export-v2 | ce208f1454b8cc48 | The difference between shallow and deep copying is only relevant for compound objects (objects that contain other objects, like lists or class instances):
* A *shallow copy* constructs a new compound object and then (to the extent
possible) inserts *references* into it to the objects found in the original. | trusted_official_docs | CPython Docs | The difference between shallow and deep copying is only relevant for compound objects (objects that contain other objects, like lists or class instances):
* A *shallow copy* constructs a new compound object and then (to the extent
possible) inserts *references* into it to the objects found in the original. | The difference between shallow and deep copying is only relevant for compound objects (objects that contain other objects, like lists or class instances):
* A *shallow copy* constructs a new compound object and then (to the extent
possible) inserts *references* into it to the objects found in the original. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
0cd9c64e-f9eb-4dfb-a983-dcfbfa94c0d7 | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,693 | supabase-export-v2 | dcc372f175221900 | .. index:: pair: module; pickle
Classes can use the same interfaces to control copying that they use to control
pickling. See the description of module :mod:`pickle` for information on these
methods. In fact, the :mod:`!copy` module uses the registered
pickle functions from the :mod:`copyreg` module. | trusted_official_docs | CPython Docs | .. index:: pair: module; pickle
Classes can use the same interfaces to control copying that they use to control
pickling. See the description of module :mod:`pickle` for information on these
methods. In fact, the :mod:`!copy` module uses the registered
pickle functions from the :mod:`copyreg` module. | .. index:: pair: module; pickle
Classes can use the same interfaces to control copying that they use to control
pickling. See the description of module :mod:`pickle` for information on these
methods. In fact, the :mod:`!copy` module uses the registered
pickle functions from the :mod:`copyreg` module. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
25eb77d3-835f-429d-b3a4-de923080173a | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,692 | supabase-export-v2 | efcaeafb4e36eb0a | Shallow copies of dictionaries can be made using :meth:`dict.copy`, and of lists by assigning a slice of the entire list, for example, ``copied_list = original_list[:]``.
.. index:: pair: module; pickle | trusted_official_docs | CPython Docs | Shallow copies of dictionaries can be made using :meth:`dict.copy`, and of lists by assigning a slice of the entire list, for example, ``copied_list = original_list[:]``.
.. index:: pair: module; pickle | Shallow copies of dictionaries can be made using :meth:`dict.copy`, and of lists by assigning a slice of the entire list, for example, ``copied_list = original_list[:]``.
.. index:: pair: module; pickle | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
2b34d0dc-5165-45fa-bf50-2bde49e78420 | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,683 | supabase-export-v2 | 799d57add0698734 | A *shallow copy* constructs a new compound object and then (to the extent possible) inserts *references* into it to the objects found in the original.
* A *deep copy* constructs a new compound object and then, recursively, inserts
*copies* into it of the objects found in the original. | trusted_official_docs | CPython Docs | A *shallow copy* constructs a new compound object and then (to the extent possible) inserts *references* into it to the objects found in the original.
* A *deep copy* constructs a new compound object and then, recursively, inserts
*copies* into it of the objects found in the original. | A *shallow copy* constructs a new compound object and then (to the extent possible) inserts *references* into it to the objects found in the original.
* A *deep copy* constructs a new compound object and then, recursively, inserts
*copies* into it of the objects found in the original. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
2e5189f7-0595-41d8-8fe7-6b290120c6bb | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,691 | supabase-export-v2 | 1828d0862bd55a7c | functions and classes (shallow and deeply), by returning the original object unchanged; this is compatible with the way these are treated by the :mod:`pickle` module.
Shallow copies of dictionaries can be made using :meth:`dict.copy`, and
of lists by assigning a slice of the entire list, for example,
``copied_list = or... | trusted_official_docs | CPython Docs | functions and classes (shallow and deeply), by returning the original object unchanged; this is compatible with the way these are treated by the :mod:`pickle` module.
Shallow copies of dictionaries can be made using :meth:`dict.copy`, and
of lists by assigning a slice of the entire list, for example,
``copied_list = or... | functions and classes (shallow and deeply), by returning the original object unchanged; this is compatible with the way these are treated by the :mod:`pickle` module.
Shallow copies of dictionaries can be made using :meth:`dict.copy`, and
of lists by assigning a slice of the entire list, for example,
``copied_list = or... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
40fbddce-e777-4081-839c-3e25bdf793a6 | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,700 | supabase-export-v2 | f10667db4b58ef3c | .. method:: object.__deepcopy__(self, memo) :noindexentry:
Called to implement the deep copy operation; it is passed one
argument, the *memo* dictionary. If the ``__deepcopy__`` implementation needs
to make a deep copy of a component, it should call the :func:`~copy.deepcopy` function
with the component as first arg... | trusted_official_docs | CPython Docs | .. method:: object.__deepcopy__(self, memo) :noindexentry:
Called to implement the deep copy operation; it is passed one
argument, the *memo* dictionary. If the ``__deepcopy__`` implementation needs
to make a deep copy of a component, it should call the :func:`~copy.deepcopy` function
with the component as first arg... | .. method:: object.__deepcopy__(self, memo) :noindexentry:
Called to implement the deep copy operation; it is passed one
argument, the *memo* dictionary. If the ``__deepcopy__`` implementation needs
to make a deep copy of a component, it should call the :func:`~copy.deepcopy` function
with the component as first arg... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
52356481-3c72-4365-91a1-6e8f5b7dabbb | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,703 | supabase-export-v2 | 61e7acb916c6aea7 | Function :func:`!copy.replace` is more limited than :func:`~copy.copy` and :func:`~copy.deepcopy`, and only supports named tuples created by :func:`~collections.namedtuple`, :mod:`dataclasses`, and other classes which define method :meth:`~object.__replace__`.
.. method:: object.__replace__(self, /, **changes)
:noinde... | trusted_official_docs | CPython Docs | Function :func:`!copy.replace` is more limited than :func:`~copy.copy` and :func:`~copy.deepcopy`, and only supports named tuples created by :func:`~collections.namedtuple`, :mod:`dataclasses`, and other classes which define method :meth:`~object.__replace__`.
.. method:: object.__replace__(self, /, **changes)
:noinde... | Function :func:`!copy.replace` is more limited than :func:`~copy.copy` and :func:`~copy.deepcopy`, and only supports named tuples created by :func:`~collections.namedtuple`, :mod:`dataclasses`, and other classes which define method :meth:`~object.__replace__`.
.. method:: object.__replace__(self, /, **changes)
:noinde... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
57c9f9e6-faf1-4212-9d9f-b15c2d540669 | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,685 | supabase-export-v2 | 51a6df43d5a81ff2 | Two problems often exist with deep copy operations that don't exist with shallow copy operations:
* Recursive objects (compound objects that, directly or indirectly, contain a
reference to themselves) may cause a recursive loop. | trusted_official_docs | CPython Docs | Two problems often exist with deep copy operations that don't exist with shallow copy operations:
* Recursive objects (compound objects that, directly or indirectly, contain a
reference to themselves) may cause a recursive loop. | Two problems often exist with deep copy operations that don't exist with shallow copy operations:
* Recursive objects (compound objects that, directly or indirectly, contain a
reference to themselves) may cause a recursive loop. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
7ce295be-9a99-409e-b544-2502b350be3a | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,690 | supabase-export-v2 | c6f87a67ada08438 | * letting user-defined classes override the copying operation or the set of components copied.
This module does not copy types like module, method, stack trace, stack frame,
file, socket, window, or any similar types. It does "copy" functions and
classes (shallow and deeply), by returning the original object unchanged;... | trusted_official_docs | CPython Docs | * letting user-defined classes override the copying operation or the set of components copied.
This module does not copy types like module, method, stack trace, stack frame,
file, socket, window, or any similar types. It does "copy" functions and
classes (shallow and deeply), by returning the original object unchanged;... | * letting user-defined classes override the copying operation or the set of components copied.
This module does not copy types like module, method, stack trace, stack frame,
file, socket, window, or any similar types. It does "copy" functions and
classes (shallow and deeply), by returning the original object unchanged;... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
8080605a-bf74-43c3-9ce9-75316b9e66a9 | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,686 | supabase-export-v2 | c6e2eaa0aa71d983 | * Recursive objects (compound objects that, directly or indirectly, contain a reference to themselves) may cause a recursive loop.
* Because deep copy copies everything it may copy too much, such as data
which is intended to be shared between copies. | trusted_official_docs | CPython Docs | * Recursive objects (compound objects that, directly or indirectly, contain a reference to themselves) may cause a recursive loop.
* Because deep copy copies everything it may copy too much, such as data
which is intended to be shared between copies. | * Recursive objects (compound objects that, directly or indirectly, contain a reference to themselves) may cause a recursive loop.
* Because deep copy copies everything it may copy too much, such as data
which is intended to be shared between copies. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
ae1ed585-4891-4fe5-9043-fd0a57b41eb3 | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,694 | supabase-export-v2 | e7861056d7f9239b | See the description of module :mod:`pickle` for information on these methods. In fact, the :mod:`!copy` module uses the registered pickle functions from the :mod:`copyreg` module.
.. index::
single: __copy__() (copy protocol)
single: __deepcopy__() (copy protocol) | trusted_official_docs | CPython Docs | See the description of module :mod:`pickle` for information on these methods. In fact, the :mod:`!copy` module uses the registered pickle functions from the :mod:`copyreg` module.
.. index::
single: __copy__() (copy protocol)
single: __deepcopy__() (copy protocol) | See the description of module :mod:`pickle` for information on these methods. In fact, the :mod:`!copy` module uses the registered pickle functions from the :mod:`copyreg` module.
.. index::
single: __copy__() (copy protocol)
single: __deepcopy__() (copy protocol) | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
bbf8edce-043d-4389-a733-92249211289b | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,701 | supabase-export-v2 | a8119522ec0bf28f | :func:`~copy.deepcopy` function with the component as first argument and the *memo* dictionary as second argument. The *memo* dictionary should be treated as an opaque object.
.. index::
single: __replace__() (replace protocol) | trusted_official_docs | CPython Docs | :func:`~copy.deepcopy` function with the component as first argument and the *memo* dictionary as second argument. The *memo* dictionary should be treated as an opaque object.
.. index::
single: __replace__() (replace protocol) | :func:`~copy.deepcopy` function with the component as first argument and the *memo* dictionary as second argument. The *memo* dictionary should be treated as an opaque object.
.. index::
single: __replace__() (replace protocol) | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
bc4fab35-3f50-4a7a-b8a7-d8b81260fb4a | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,684 | supabase-export-v2 | 724d5a70673b1502 | * A *deep copy* constructs a new compound object and then, recursively, inserts *copies* into it of the objects found in the original.
Two problems often exist with deep copy operations that don't exist with shallow
copy operations: | trusted_official_docs | CPython Docs | * A *deep copy* constructs a new compound object and then, recursively, inserts *copies* into it of the objects found in the original.
Two problems often exist with deep copy operations that don't exist with shallow
copy operations: | * A *deep copy* constructs a new compound object and then, recursively, inserts *copies* into it of the objects found in the original.
Two problems often exist with deep copy operations that don't exist with shallow
copy operations: | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f178348a-fd2b-405d-94a4-137140ced8d4 | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,702 | supabase-export-v2 | da864ae4dc8c8832 | .. index:: single: __replace__() (replace protocol)
Function :func:`!copy.replace` is more limited
than :func:`~copy.copy` and :func:`~copy.deepcopy`,
and only supports named tuples created by :func:`~collections.namedtuple`,
:mod:`dataclasses`, and other classes which define method :meth:`~object.__replace__`. | trusted_official_docs | CPython Docs | .. index:: single: __replace__() (replace protocol)
Function :func:`!copy.replace` is more limited
than :func:`~copy.copy` and :func:`~copy.deepcopy`,
and only supports named tuples created by :func:`~collections.namedtuple`,
:mod:`dataclasses`, and other classes which define method :meth:`~object.__replace__`. | .. index:: single: __replace__() (replace protocol)
Function :func:`!copy.replace` is more limited
than :func:`~copy.copy` and :func:`~copy.deepcopy`,
and only supports named tuples created by :func:`~collections.namedtuple`,
:mod:`dataclasses`, and other classes which define method :meth:`~object.__replace__`. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
f6572be2-7270-4f01-86cf-26e2ed5a4f47 | CPython Docs | file://datasets/cpython/Doc/library/copy.rst | unknown | 41762798-feac-4a05-8c7f-2d91c38693d6 | 21,671 | supabase-export-v2 | dd78937c283fe68a | --------------
Assignment statements in Python do not copy objects, they create bindings
between a target and an object. For collections that are mutable or contain
mutable items, a copy is sometimes needed so one can change one copy without
changing the other. This module provides generic shallow and deep copy
operati... | trusted_official_docs | CPython Docs | --------------
Assignment statements in Python do not copy objects, they create bindings
between a target and an object. For collections that are mutable or contain
mutable items, a copy is sometimes needed so one can change one copy without
changing the other. This module provides generic shallow and deep copy
operati... | --------------
Assignment statements in Python do not copy objects, they create bindings
between a target and an object. For collections that are mutable or contain
mutable items, a copy is sometimes needed so one can change one copy without
changing the other. This module provides generic shallow and deep copy
operati... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
02821ae7-e6a7-4122-862a-397cf91aa269 | CPython Docs | file://datasets/cpython/Doc/library/email.mime.rst | unknown | 7f625516-aaaf-44c2-a359-84db86b0cb0b | 21,733 | supabase-export-v2 | c3aa902c4058f78d | Optional *policy* argument defaults to :class:`compat32 <email.policy.Compat32>`.
Additional parameters for the :mailheader:`Content-Type` header are taken from
the keyword arguments, or passed into the *_params* argument, which is a keyword
dictionary. | trusted_official_docs | CPython Docs | Optional *policy* argument defaults to :class:`compat32 <email.policy.Compat32>`.
Additional parameters for the :mailheader:`Content-Type` header are taken from
the keyword arguments, or passed into the *_params* argument, which is a keyword
dictionary. | Optional *policy* argument defaults to :class:`compat32 <email.policy.Compat32>`.
Additional parameters for the :mailheader:`Content-Type` header are taken from
the keyword arguments, or passed into the *_params* argument, which is a keyword
dictionary. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
0f29e45a-47a0-47ad-b28b-eefb70a7aa9f | CPython Docs | file://datasets/cpython/Doc/library/email.mime.rst | unknown | 7f625516-aaaf-44c2-a359-84db86b0cb0b | 21,712 | supabase-export-v2 | 7d6f68c1f5063bc0 | functionality is partially replaced by the :mod:`~email.contentmanager` in the new API, but in certain applications these classes may still be useful, even in non-legacy code.
Ordinarily, you get a message object structure by passing a file or some text to
a parser, which parses the text and returns the root message ob... | trusted_official_docs | CPython Docs | functionality is partially replaced by the :mod:`~email.contentmanager` in the new API, but in certain applications these classes may still be useful, even in non-legacy code.
Ordinarily, you get a message object structure by passing a file or some text to
a parser, which parses the text and returns the root message ob... | functionality is partially replaced by the :mod:`~email.contentmanager` in the new API, but in certain applications these classes may still be useful, even in non-legacy code.
Ordinarily, you get a message object structure by passing a file or some text to
a parser, which parses the text and returns the root message ob... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
140ab9bc-6949-432c-a667-db6004f250fb | CPython Docs | file://datasets/cpython/Doc/library/email.mime.rst | unknown | 7f625516-aaaf-44c2-a359-84db86b0cb0b | 21,734 | supabase-export-v2 | 6d1d5bae5e15829e | Additional parameters for the :mailheader:`Content-Type` header are taken from the keyword arguments, or passed into the *_params* argument, which is a keyword dictionary.
.. versionchanged:: 3.6
Added *policy* keyword-only parameter. | trusted_official_docs | CPython Docs | Additional parameters for the :mailheader:`Content-Type` header are taken from the keyword arguments, or passed into the *_params* argument, which is a keyword dictionary.
.. versionchanged:: 3.6
Added *policy* keyword-only parameter. | Additional parameters for the :mailheader:`Content-Type` header are taken from the keyword arguments, or passed into the *_params* argument, which is a keyword dictionary.
.. versionchanged:: 3.6
Added *policy* keyword-only parameter. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
1b00da96-3e48-4d7b-8080-8a974f73bf10 | CPython Docs | file://datasets/cpython/Doc/library/email.mime.rst | unknown | 7f625516-aaaf-44c2-a359-84db86b0cb0b | 21,739 | supabase-export-v2 | 0335e82bdb26ad55 | message objects of major type :mimetype:`application`. *_data* contains the bytes for the raw application data. Optional *_subtype* specifies the MIME subtype and defaults to :mimetype:`octet-stream`.
Optional *_encoder* is a callable (i.e. function) which will perform the actual
encoding of the data for transport. Th... | trusted_official_docs | CPython Docs | message objects of major type :mimetype:`application`. *_data* contains the bytes for the raw application data. Optional *_subtype* specifies the MIME subtype and defaults to :mimetype:`octet-stream`.
Optional *_encoder* is a callable (i.e. function) which will perform the actual
encoding of the data for transport. Th... | message objects of major type :mimetype:`application`. *_data* contains the bytes for the raw application data. Optional *_subtype* specifies the MIME subtype and defaults to :mimetype:`octet-stream`.
Optional *_encoder* is a callable (i.e. function) which will perform the actual
encoding of the data for transport. Th... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
285e8073-0119-46a9-837f-0df1082c2daa | CPython Docs | file://datasets/cpython/Doc/library/email.mime.rst | unknown | 7f625516-aaaf-44c2-a359-84db86b0cb0b | 21,762 | supabase-export-v2 | 004a2b7fe0a3f5d8 | Module: :mod:`email.mime.message`
A subclass of :class:`~email.mime.nonmultipart.MIMENonMultipart`, the
:class:`MIMEMessage` class is used to create MIME objects of main type
:mimetype:`message`. *_msg* is used as the payload, and must be an instance
of class :class:`~email.message.Message` (or a subclass thereof), ... | trusted_official_docs | CPython Docs | Module: :mod:`email.mime.message`
A subclass of :class:`~email.mime.nonmultipart.MIMENonMultipart`, the
:class:`MIMEMessage` class is used to create MIME objects of main type
:mimetype:`message`. *_msg* is used as the payload, and must be an instance
of class :class:`~email.message.Message` (or a subclass thereof), ... | Module: :mod:`email.mime.message`
A subclass of :class:`~email.mime.nonmultipart.MIMENonMultipart`, the
:class:`MIMEMessage` class is used to create MIME objects of main type
:mimetype:`message`. *_msg* is used as the payload, and must be an instance
of class :class:`~email.message.Message` (or a subclass thereof), ... | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
3036c835-e553-4cb3-84a1-1513c5cc94e9 | CPython Docs | file://datasets/cpython/Doc/library/email.mime.rst | unknown | 7f625516-aaaf-44c2-a359-84db86b0cb0b | 21,763 | supabase-export-v2 | 3d1b97a8bc799c8d | type :mimetype:`message`. *_msg* is used as the payload, and must be an instance of class :class:`~email.message.Message` (or a subclass thereof), otherwise a :exc:`TypeError` is raised.
Optional *_subtype* sets the subtype of the message; it defaults to
:mimetype:`rfc822`. | trusted_official_docs | CPython Docs | type :mimetype:`message`. *_msg* is used as the payload, and must be an instance of class :class:`~email.message.Message` (or a subclass thereof), otherwise a :exc:`TypeError` is raised.
Optional *_subtype* sets the subtype of the message; it defaults to
:mimetype:`rfc822`. | type :mimetype:`message`. *_msg* is used as the payload, and must be an instance of class :class:`~email.message.Message` (or a subclass thereof), otherwise a :exc:`TypeError` is raised.
Optional *_subtype* sets the subtype of the message; it defaults to
:mimetype:`rfc822`. | python, official-docs, cpython, P0 | Local_Trusted_Corpus | |
36fc70f8-915c-484d-b1f3-277657e399c1 | CPython Docs | file://datasets/cpython/Doc/library/email.mime.rst | unknown | 7f625516-aaaf-44c2-a359-84db86b0cb0b | 21,718 | supabase-export-v2 | 5e7950c903bf1b0e | Ordinarily you won't create instances specifically of :class:`MIMEBase`, although you could. :class:`MIMEBase` is provided primarily as a convenient base class for more specific MIME-aware subclasses.
*_maintype* is the :mailheader:`Content-Type` major type (e.g. :mimetype:`text`
or :mimetype:`image`), and *_subtype* ... | trusted_official_docs | CPython Docs | Ordinarily you won't create instances specifically of :class:`MIMEBase`, although you could. :class:`MIMEBase` is provided primarily as a convenient base class for more specific MIME-aware subclasses.
*_maintype* is the :mailheader:`Content-Type` major type (e.g. :mimetype:`text`
or :mimetype:`image`), and *_subtype* ... | Ordinarily you won't create instances specifically of :class:`MIMEBase`, although you could. :class:`MIMEBase` is provided primarily as a convenient base class for more specific MIME-aware subclasses.
*_maintype* is the :mailheader:`Content-Type` major type (e.g. :mimetype:`text`
or :mimetype:`image`), and *_subtype* ... | 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.