https://github.com/python/cpython/commit/9d0ca237af669ffde8c97b628c16b51792b5a3b6
commit: 9d0ca237af669ffde8c97b628c16b51792b5a3b6
branch: 3.14
author: Miss Islington (bot) <[email protected]>
committer: hugovk <[email protected]>
date: 2025-09-17T18:51:30+03:00
summary:

[3.14] gh-137988: Fix const description in argparse.add_argument() docs 
(GH-138315) (#139051)

Co-authored-by: PrinceNaroliya <[email protected]>
Co-authored-by: Savannah Bailey <[email protected]>

files:
M Doc/library/argparse.rst

diff --git a/Doc/library/argparse.rst b/Doc/library/argparse.rst
index 79e15994491eff..ef8242f5f780f5 100644
--- a/Doc/library/argparse.rst
+++ b/Doc/library/argparse.rst
@@ -981,8 +981,8 @@ the various :class:`ArgumentParser` actions.  The two most 
common uses of it are
   (like ``-f`` or ``--foo``) and ``nargs='?'``.  This creates an optional
   argument that can be followed by zero or one command-line arguments.
   When parsing the command line, if the option string is encountered with no
-  command-line argument following it, the value of ``const`` will be assumed to
-  be ``None`` instead.  See the nargs_ description for examples.
+  command-line argument following it, the value from ``const`` will be used.
+  See the nargs_ description for examples.
 
 .. versionchanged:: 3.11
    ``const=None`` by default, including when ``action='append_const'`` or

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]

Reply via email to