Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

collections.abc.ByteString does not register memoryview #78045

Closed
fried mannequin opened this issue Jun 14, 2018 · 6 comments
Closed

collections.abc.ByteString does not register memoryview #78045

fried mannequin opened this issue Jun 14, 2018 · 6 comments
Labels
3.7 (EOL) end of life 3.8 only security fixes docs Documentation in the Doc dir type-bug An unexpected behavior, bug, or error

Comments

@fried
Copy link
Mannequin

fried mannequin commented Jun 14, 2018

BPO 33864
Nosy @rhettinger, @ambv, @MojoVampire, @fried, @ZackerySpytz, @miss-islington
PRs
  • bpo-33864: Clarify the docs for typing.ByteString #21311
  • [3.9] bpo-33864: Clarify the docs for typing.ByteString (GH-21311) #21312
  • [3.8] bpo-33864: Clarify the docs for typing.ByteString (GH-21311) #21313
  • 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 2020-07-04.04:23:04.205>
    created_at = <Date 2018-06-14.21:43:36.836>
    labels = ['3.8', 'type-bug', '3.7', 'docs']
    title = 'collections.abc.ByteString does not register memoryview'
    updated_at = <Date 2020-07-04.04:23:04.205>
    user = 'https://github.com/fried'

    bugs.python.org fields:

    activity = <Date 2020-07-04.04:23:04.205>
    actor = 'gvanrossum'
    assignee = 'docs@python'
    closed = True
    closed_date = <Date 2020-07-04.04:23:04.205>
    closer = 'gvanrossum'
    components = ['Documentation']
    creation = <Date 2018-06-14.21:43:36.836>
    creator = 'fried'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 33864
    keywords = ['patch']
    message_count = 6.0
    messages = ['319557', '319604', '319724', '372976', '372977', '372978']
    nosy_count = 7.0
    nosy_names = ['rhettinger', 'docs@python', 'lukasz.langa', 'josh.r', 'fried', 'ZackerySpytz', 'miss-islington']
    pr_nums = ['21311', '21312', '21313']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue33864'
    versions = ['Python 3.6', 'Python 3.7', 'Python 3.8']

    @fried
    Copy link
    Mannequin Author

    fried mannequin commented Jun 14, 2018

    Looking at the typing Module docs in the section for ByteString

    This type represents the types bytes, bytearray, and memoryview.

    But collections.abc.ByteString does not have memoryview registered.

    Is it because memoryview doesn't support .index()?

    @fried fried mannequin added 3.7 (EOL) end of life 3.8 only security fixes labels Jun 14, 2018
    @fried fried mannequin assigned docspython Jun 14, 2018
    @fried fried mannequin added docs Documentation in the Doc dir type-bug An unexpected behavior, bug, or error labels Jun 14, 2018
    @MojoVampire
    Copy link
    Mannequin

    MojoVampire mannequin commented Jun 15, 2018

    memoryview isn't just for bytes strings though; the format can make it a sequence of many types of different widths, meanings, etc. Calling it a BytesString would be misleading in many cases.

    @rhettinger
    Copy link
    Contributor

    The docs should be made more precise. Perhaps, "This type represents the types bytes, bytearray, and memoryview of byte sequences"?

    @miss-islington
    Copy link
    Contributor

    New changeset b40e434 by Zackery Spytz in branch 'master':
    bpo-33864: Clarify the docs for typing.ByteString (GH-21311)
    b40e434

    @miss-islington
    Copy link
    Contributor

    New changeset 1cbcf98 by Miss Islington (bot) in branch '3.9':
    bpo-33864: Clarify the docs for typing.ByteString (GH-21311)
    1cbcf98

    @miss-islington
    Copy link
    Contributor

    New changeset 6857ebe by Miss Islington (bot) in branch '3.8':
    bpo-33864: Clarify the docs for typing.ByteString (GH-21311)
    6857ebe

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.7 (EOL) end of life 3.8 only security fixes docs Documentation in the Doc dir type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    3 participants