| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
| |
(cherry picked from commit be5c79e0338005d675a64ba6e5b137e850d556d1)
Co-authored-by: Federico Bond <federicobond@gmail.com>
|
| |
|
|
|
| |
This reverts commit b50eff65906f8e9b4597cb0128ea1729341346fc because
it's an incompatible change that would have broken the existing
translations.
|
| |
|
|
|
| |
(cherry picked from commit 42671aea2db6cbc54369617da0fd3545048e0a45)
Co-authored-by: Jakub Kulík <Kulikjak@gmail.com>
|
| |
|
|
|
|
|
|
| |
(GH-14976)
Co-authored-by: Andrew Nester <andrew.nester.dev@gmail.com>
Co-authored-by: Flavian Hautbois <flavianh@sicara.com>
(cherry picked from commit da27d9b9dc44913ffee8f28d9638985eaaa03755)
|
| |
|
|
|
|
|
|
| |
- bugfix and test for fragile metavar handling in argparse (see
bpo-24089, bpo-14046, bpo-25058, bpo-11874)
- also fixes some incorrect tests that did not make 1-element tuples correctly
(cherry picked from commit 66f02aa32f1e4adb9f24cf186f8c495399d5ce9b)
Co-authored-by: wim glenn <wim.glenn@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
(GH-6919) (GH-7089)
bpo-26510 in 3.7.0a2 changed the behavior of argparse to make
subparsers required by default, returning to the behavior of 2.7
and 3.2. The behavior was changed in 3.3 to be no longer required.
While it might make more sense to have the default to required,
compatibility with 3.3 through 3.6 is probably less disruptive
than trying to reintroduce compatibility with 2.7 at this point.
This change restores the 3.6 behavior.
(cherry picked from commit 8ebf5ceb0f5408d1ebc26c19702ac0762ef5ea04)
Co-authored-by: Ned Deily <nad@python.org>
|
| | |
|
| | |
|
| |
|
|
|
|
| |
This fixes a regression from Python 2. To get optional subparsers,
use the new parameter ``add_subparsers(required=False)``.
Patch by Anthony Sottile.
|
| |
|
| |
This adds support for parsing a command line where options and positionals are intermixed as is common in many unix commands. This is paul.j3's patch with a few tweaks.
|
| |\ |
|
| | | |
|
| | | |
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Output of func(*args) stored in the next line:
item_help = join([func(*args) for func, args in self.items])
_Section.items only used by HelpFormatter._add_item() and it looks
like it doesn't have any side effects.
Patch by Yogesh Chaudhari.
|
| |/
|
|
| |
Patch by Matthias Bussonnier.
|
| |
|
|
| |
Patch by Jonathan Paugh, Steven Bethard, paul j3 and Daniel Eriksson.
|
| |
|
|
| |
implementation in issue #21408 they are redundant.
|
| | |
|
| |
|
|
|
|
|
|
| |
Before, if a default was set on the parent parser, any default for that
variable set via set_defaults on a subparser would be ignored. Now
the subparser set_defaults is honored.
Patch by Jyrki Pullianinen.
|
| |
|
|
| |
comparing to unknown types.
|
| |\
| |
| |
| |
| | |
a help on environment with too small COLUMNS. Based on patch by
Elazar Gershuni.
|
| | |
| |
| |
| |
| | |
a help on environment with too small COLUMNS. Based on patch by
Elazar Gershuni.
|
| | |
| |
| |
| |
| |
| | |
output to stdout, matching the 'python -v'
Reported by Wolfgang Maier
|
| | |
| |
| |
| | |
as reported by Serhiy Storchaka and Matthew Barnett.
|
| | | |
|
| | | |
|
| | |
| |
| |
| | |
Patch by Lucas Maystre.
|
| |/ |
|
| |\ |
|
| | | |
|
| | |
| |
| |
| |
| |
| |
| |
| | |
on the action's default, reverting it back to previous behavior. Conversion
is only done on string defaults.
Add a test for this and another test that ensures such type conversions are
only called once.
|
| |\ \
| |/
| |
| | |
when action='append', type='str' and default=[].
|
| | |
| |
| |
| | |
when action='append', type='str' and default=[].
|
| |\ \
| |/
| |
| |
| |
| |
| |
| | |
This fixes a regression introduced by the fix for issue #13922. Although args
is not documented as being allowed to be a tuple, previously this worked and
so naturally there are programs in the field that depend on it.
Patch by Zbyszek Jędrzejewski-Szmek.
|
| | |
| |
| |
| |
| |
| |
| |
| | |
This fixes a regression introduced by the fix for issue #13922. Although args
is not documented as being allowed to be a tuple, previously this worked and
so naturally there are programs in the field that depend on it.
Patch by Zbyszek Jędrzejewski-Szmek.
|
| |\ \
| |/
| |
| |
| |
| |
| |
| |
| | |
Before, the type function was called twice in the case where the default
was specified and the argument was given as well. This was especially
problematic for the FileType type, as a default file would always be
opened, even if a file argument was specified on the command line.
Patch by Arnaud Fontaine, with additional test by Mike Meyer.
|
| | |
| |
| |
| |
| |
| |
| |
| |
| | |
Before, the type function was called twice in the case where the default
was specified and the argument was given as well. This was especially
problematic for the FileType type, as a default file would always be
opened, even if a file argument was specified on the command line.
Patch by Arnaud Fontaine, with additional test by Mike Meyer.
|
| |\ \
| |/
| |
| | |
Patch by Jeff Knupp.
|
| | |
| |
| |
| | |
Patch by Jeff Knupp.
|
| |\ \
| |/
| |
| | |
Patch by Torsten Landschoff.
|
| | |
| |
| |
| | |
Patch by Torsten Landschoff.
|
| |\ \
| |/ |
|
| | | |
|
| | | |
|
| |\ \
| |/ |
|
| | | |
|
| | | |
|
| | |
| |
| |
| | |
Fix and initial test patch by Michele Orrù.
|
| |\ \
| |/ |
|