Skip to content

the help for bytearray.maketrans describes bytes.maketrans #56594

Closed

Description

@py-user
mannequin
BPO 12385
Nosy @bitdancer, @py-user

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 2011-06-27.16:07:25.933>
created_at = <Date 2011-06-21.23:35:00.296>
labels = ['type-bug', 'docs']
title = 'the help for bytearray.maketrans describes bytes.maketrans'
updated_at = <Date 2011-06-27.16:07:25.931>
user = 'https://github.com/py-user'

bugs.python.org fields:

activity = <Date 2011-06-27.16:07:25.931>
actor = 'python-dev'
assignee = 'docs@python'
closed = True
closed_date = <Date 2011-06-27.16:07:25.933>
closer = 'python-dev'
components = ['Documentation']
creation = <Date 2011-06-21.23:35:00.296>
creator = 'py.user'
dependencies = []
files = []
hgrepos = []
issue_num = 12385
keywords = []
message_count = 3.0
messages = ['138808', '138810', '139308']
nosy_count = 4.0
nosy_names = ['r.david.murray', 'docs@python', 'py.user', 'python-dev']
pr_nums = []
priority = 'normal'
resolution = 'fixed'
stage = 'resolved'
status = 'closed'
superseder = None
type = 'behavior'
url = 'https://bugs.python.org/issue12385'
versions = ['Python 3.2', 'Python 3.3']

Activity

  1. py-user commented on Jun 21, 2011

    py-usermannequin
    MannequinAuthor
    help(bytearray.maketrans)
    
    maketrans(...)
        B.maketrans(frm, to) -> translation table
        
        Return a translation table (a bytes object of length 256)
        suitable for use in bytes.translate where each byte in frm is
        mapped to the byte at the same position in to.
        The strings frm and to must be of the same length.
  2. bitdancer commented on Jun 22, 2011

    @bitdancer
    Member

    Hmm. I wonder why we have two copies of this method.

    Well, given that we do, the best fix for the docs would be to say "for use in the bytes or bytearray translate method" in both this docstring and the bytes.maketrans docstring.

  3. python-dev commented on Jun 27, 2011

    python-devmannequin
    Mannequin

    New changeset 586745894ab8 by Senthil Kumaran in branch '3.2':
    Fix closes bpo-12385 - Clarify maketrans method docstring for bytes and bytearray object.
    http://hg.python.org/cpython/rev/586745894ab8

  4. transferred this issue fromon Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    docsDocumentation in the Doc dirtype-bugAn unexpected behavior, bug, or error

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions