]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-72406: Document argument ordering in argparse help output (#148534)
authorSanti Hernandez <santi@santihdzs.com>
Tue, 14 Apr 2026 16:24:16 +0000 (10:24 -0600)
committerGitHub <noreply@github.com>
Tue, 14 Apr 2026 16:24:16 +0000 (16:24 +0000)
Co-authored-by: Savannah Ostrowski <savannah@python.org>
Doc/library/argparse.rst

index 0091bf95f0cef06ea1aa83cf73afdf419dc50371..e37afd6d0b6d5aa9f875c851ba472ec4ebc6c889 100644 (file)
@@ -2032,6 +2032,9 @@ Argument groups
    Note that any arguments not in your user-defined groups will end up back
    in the usual "positional arguments" and "optional arguments" sections.
 
+   Within each argument group, arguments are displayed in help output in the
+   order in which they are added.
+
    .. deprecated-removed:: 3.11 3.14
       Calling :meth:`add_argument_group` on an argument group now raises an
       exception. This nesting was never supported, often failed to work