mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
[3.13] gh-126180: Remove getopt and optparse deprecation notices (GH-128191)
* Remove getopt and optparse deprecation notices
* Add new docs sections for command line app helper libraries
* Add guidance on choosing a CLI parsing library to the optparse docs
* Link to the new guidance from the argparse and getopt docs
* Reword intro in docs section for superseded stdlib modules
* Reframe the optparse->argparse guide as a migration guide
rather than as an upgrade guide
---------
(cherry picked from commit 831b6de6d7
)
Co-authored-by: Alyssa Coghlan <ncoghlan@gmail.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
This commit is contained in:
parent
09d15aa9a8
commit
6f3c2c8d04
12 changed files with 266 additions and 65 deletions
|
@ -11,6 +11,18 @@
|
|||
|
||||
**Source code:** :source:`Lib/argparse.py`
|
||||
|
||||
.. note::
|
||||
|
||||
While :mod:`argparse` is the default recommended standard library module
|
||||
for implementing basic command line applications, authors with more
|
||||
exacting requirements for exactly how their command line applications
|
||||
behave may find it doesn't provide the necessary level of control.
|
||||
Refer to :ref:`choosing-an-argument-parser` for alternatives to
|
||||
consider when ``argparse`` doesn't support behaviors that the application
|
||||
requires (such as entirely disabling support for interspersed options and
|
||||
positional arguments, or accepting option parameter values that start
|
||||
with ``-`` even when they correspond to another defined option).
|
||||
|
||||
--------------
|
||||
|
||||
.. sidebar:: Tutorial
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue