[Python-checkins] bpo-42194: Add "New in version: 3.9" to argparse.BooleanOptionalAction (GH-23026) (#27097)
ambv
webhook-mailer at python.org
Mon Jul 12 11:43:25 EDT 2021
https://github.com/python/cpython/commit/721d4796be60e6a0a11dee8318794f78928648c1
commit: 721d4796be60e6a0a11dee8318794f78928648c1
branch: 3.10
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: ambv <lukasz at langa.pl>
date: 2021-07-12T17:43:16+02:00
summary:
bpo-42194: Add "New in version: 3.9" to argparse.BooleanOptionalAction (GH-23026) (#27097)
(cherry picked from commit da2e673c53974641a0e13941950e7976bbda64d5)
Co-authored-by: David Sanders <shang.xiao.sanders at gmail.com>
files:
M Doc/library/argparse.rst
diff --git a/Doc/library/argparse.rst b/Doc/library/argparse.rst
index b2eb9eff914c6..a1b4bd0fcfd17 100644
--- a/Doc/library/argparse.rst
+++ b/Doc/library/argparse.rst
@@ -853,6 +853,8 @@ is available in ``argparse`` and adds support for boolean actions such as
>>> parser.parse_args(['--no-foo'])
Namespace(foo=False)
+.. versionadded:: 3.9
+
The recommended way to create a custom action is to extend :class:`Action`,
overriding the ``__call__`` method and optionally the ``__init__`` and
``format_usage`` methods.
More information about the Python-checkins
mailing list