python / python/cpython

argparse does not preserve namespace with subparser defaults

Open
#89,398 23 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

3.12 stdlib type-bug
Dominant language
Python
Stars
77.2k
Forks
36k
Avg merge
1d 9h
Merged PRs (30d)
558

Description

BPO 45235
Nosy @rhettinger, @ambv, @pablogsal, @miss-islington, @FrostMing, @RhinosF1, @ALSchwalm, @dgw, @lwalejko
PRs
  • python/cpython#28420
  • python/cpython#28442
  • python/cpython#28443
  • python/cpython#29525
  • python/cpython#29530
  • python/cpython#29531
  • python/cpython#29574
  • python/cpython#30219
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = None
    created_at = <Date 2021-09-17.14:58:54.103>
    labels = ['type-bug', '3.8', '3.9', '3.10', '3.11', '3.7', 'library']
    title = 'argparse does not preserve namespace with subparser defaults'
    updated_at = <Date 2021-12-22.19:20:37.779>
    user = 'https://github.com/ALSchwalm'
    

    bugs.python.org fields:

    activity = <Date 2021-12-22.19:20:37.779>
    actor = 'gvanrossum'
    assignee = 'none'
    closed = False
    closed_date = None
    closer = None
    components = ['Library (Lib)']
    creation = <Date 2021-09-17.14:58:54.103>
    creator = 'ALSchwalm'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 45235
    keywords = ['patch']
    message_count = 23.0
    messages = ['402060', '402120', '402121', '402122', '404990', '404991', '405007', '405129', '406052', '406079', '406121', '406123', '406128', '406171', '406172', '406175', '406186', '406231', '406232', '406233', '406571', '406814', '408991']
    nosy_count = 10.0
    nosy_names = ['rhettinger', 'lukasz.langa', 'paul.j3', 'pablogsal', 'miss-islington', 'Frost Ming', 'RhinosF1', 'ALSchwalm', 'dgw', 'lwalejko']
    pr_nums = ['28420', '28442', '28443', '29525', '29530', '29531', '29574', '30219']
    priority = 'normal'
    resolution = None
    stage = 'patch review'
    status = 'open'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue45235'
    versions = ['Python 3.6', 'Python 3.7', 'Python 3.8', 'Python 3.9', 'Python 3.10', 'Python 3.11']
    

    Contributor guide

    Open the contributing guide

    First steps

    1. Read the whole issue, then the project's contributing guide.
    2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
    3. Fork the repository and make your change on a branch.
    4. Open a pull request that references the issue number.

    Research direction

    The issue names argparse subparsers but no source file, test, reproduction, or expected result. Start by reviewing argparse's subparser namespace handling and the existing PRs 28420, 28442, 28443, 29525, 29530, 29531, 29574, and 30219; done means the reported namespace behavior is corrected and covered by an appropriate test.

    Written by the indexing model from the issue text.

    Assessment

    Tech stack
    python
    Domain
    cli
    Issue type
    Bug
    Difficulty
    4/5
    Estimated time
    3-5 days
    Activity status
    Stale
    Clarity
    Needs clarification
    Newbie friendliness
    25/100

    Get new issues in your inbox

    A short digest of beginner-friendly GitHub issues.