Skip to content

Exceptions and arguments disappear when using argparse inside with statement #68258

@invisibleroads

Description

@invisibleroads
BPO 24070
Nosy @benjaminp, @bitdancer
Dependencies
  • bpo-9938: Add optional keyword argument exit_on_error to argparse.ArgumentParser
  • Files
  • argparse-with-exception.py
  • 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 = <Date 2015-04-28.18:29:16.040>
    created_at = <Date 2015-04-28.17:57:25.650>
    labels = ['type-bug', 'library']
    title = 'Exceptions and arguments disappear when using argparse inside with statement'
    updated_at = <Date 2015-05-06.17:52:11.294>
    user = 'https://bugs.python.org/invisibleroads'

    bugs.python.org fields:

    activity = <Date 2015-05-06.17:52:11.294>
    actor = 'r.david.murray'
    assignee = 'none'
    closed = True
    closed_date = <Date 2015-04-28.18:29:16.040>
    closer = 'benjamin.peterson'
    components = ['Library (Lib)']
    creation = <Date 2015-04-28.17:57:25.650>
    creator = 'invisibleroads'
    dependencies = ['9938']
    files = ['39227']
    hgrepos = []
    issue_num = 24070
    keywords = []
    message_count = 4.0
    messages = ['242192', '242196', '242692', '242693']
    nosy_count = 3.0
    nosy_names = ['benjamin.peterson', 'invisibleroads', 'r.david.murray']
    pr_nums = []
    priority = 'normal'
    resolution = 'duplicate'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue24070'
    versions = ['Python 2.7', 'Python 3.4', 'Python 3.5']

    Metadata

    Metadata

    Assignees

    No one assigned

      Labels

      stdlibStandard Library Python modules in the Lib/ directorytype-bugAn unexpected behavior, bug, or error
      No fields configured for issues without a type.

      Projects

      No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions