Skip to content

argparse.FileType for '-' doesn't work for a mode of 'rb' #58364

@anacrolix

Description

@anacrolix
mannequin
BPO 14156
Nosy @naufraghi, @bitdancer, @serhiy-storchaka, @mgrandi, @MojoVampire, @Lekensteyn, @palaviv, @evanunderscore, @sedrubal, @miss-islington, @woodruffw
PRs
  • bpo-14156:Add argparse.FileType for a mode of 'rb' and 'wb' #9124
  • bpo-14156: Make argparse.FileType work correctly for binary file mode… #13165
  • [3.10] bpo-14156: Make argparse.FileType work correctly for binary file modes when argument is '-' (GH-13165) #31706
  • [3.9] bpo-14156: Make argparse.FileType work correctly for binary fil… #31979
  • Files
  • argparse-filetype-stdio-modes.patch
  • 14156.patch
  • 14156-2.patch: patch with tests working
  • 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 2022-03-18.15:03:40.764>
    created_at = <Date 2012-02-29.11:01:10.726>
    labels = ['type-bug', 'library', '3.9', '3.10', '3.11']
    title = "argparse.FileType for '-' doesn't work for a mode of 'rb'"
    updated_at = <Date 2022-03-18.15:03:40.762>
    user = 'https://github.com/anacrolix'

    bugs.python.org fields:

    activity = <Date 2022-03-18.15:03:40.762>
    actor = 'serhiy.storchaka'
    assignee = 'none'
    closed = True
    closed_date = <Date 2022-03-18.15:03:40.764>
    closer = 'serhiy.storchaka'
    components = ['Library (Lib)']
    creation = <Date 2012-02-29.11:01:10.726>
    creator = 'anacrolix'
    dependencies = []
    files = ['24868', '26484', '42072']
    hgrepos = []
    issue_num = 14156
    keywords = ['patch', 'needs review']
    message_count = 33.0
    messages = ['154612', '154641', '155761', '155923', '162342', '166170', '215299', '215410', '221271', '221456', '221457', '261218', '282851', '282922', '282948', '283210', '283213', '283216', '283463', '293095', '294544', '297997', '298237', '324859', '324892', '325011', '341767', '341796', '373025', '414479', '414614', '414615', '415501']
    nosy_count = 17.0
    nosy_names = ['bethard', 'naufraghi', 'r.david.murray', 'eli.bendersky', 'paul.j3', 'serhiy.storchaka', 'moritz', 'markgrandi', 'josh.r', 'lekensteyn', 'palaviv', 'evan_', 'sedrubal', 'Marcel H2', 'miss-islington', 'Leo Singer', 'yossarian']
    pr_nums = ['9124', '13165', '31706', '31979']
    priority = 'high'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue14156'
    versions = ['Python 3.9', 'Python 3.10', 'Python 3.11']

    Metadata

    Metadata

    Assignees

    No one assigned

      Labels

      3.10only security fixes3.11only security fixes3.9 (EOL)end of lifestdlibStandard Library Python modules in the Lib/ directorytype-bugAn unexpected behavior, bug, or error

      Projects

      No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions