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

Improve docs for str.splitlines #59162

Closed
ncoghlan opened this issue May 29, 2012 · 5 comments
Closed

Improve docs for str.splitlines #59162

ncoghlan opened this issue May 29, 2012 · 5 comments
Labels
docs Documentation in the Doc dir easy type-bug An unexpected behavior, bug, or error

Comments

@ncoghlan
Copy link
Contributor

BPO 14957
Nosy @ncoghlan, @merwok, @bitdancer
Files
  • stdtypes.patch: patch for str documentation
  • 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 2012-06-01.20:22:28.788>
    created_at = <Date 2012-05-29.22:34:50.078>
    labels = ['easy', 'type-bug', 'docs']
    title = 'Improve docs for str.splitlines'
    updated_at = <Date 2012-06-02.15:21:48.939>
    user = 'https://github.com/ncoghlan'

    bugs.python.org fields:

    activity = <Date 2012-06-02.15:21:48.939>
    actor = 'python-dev'
    assignee = 'docs@python'
    closed = True
    closed_date = <Date 2012-06-01.20:22:28.788>
    closer = 'r.david.murray'
    components = ['Documentation']
    creation = <Date 2012-05-29.22:34:50.078>
    creator = 'ncoghlan'
    dependencies = []
    files = ['25791']
    hgrepos = []
    issue_num = 14957
    keywords = ['patch', 'easy']
    message_count = 5.0
    messages = ['161915', '162102', '162104', '162105', '162142']
    nosy_count = 6.0
    nosy_names = ['ncoghlan', 'eric.araujo', 'r.david.murray', 'docs@python', 'python-dev', 'michael.driscoll']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue14957'
    versions = ['Python 2.7', 'Python 3.2', 'Python 3.3']

    @ncoghlan
    Copy link
    Contributor Author

    The docs for str.splitlines() should explain:

    1. That it uses the universal newlines approach to splitting lines
    2. That unlike str.split() a trailing empty line is *not* included in the resulting list

    @ncoghlan ncoghlan added the docs Documentation in the Doc dir label May 29, 2012
    @merwok merwok added the easy label Jun 1, 2012
    @michaeldriscoll
    Copy link
    Mannequin

    michaeldriscoll mannequin commented Jun 1, 2012

    I'm assuming Nick is talking about the stdtypes.rst (in Doc/library) file, correct? If so, I went ahead and created a simple patch that almost uses his verbiage verbatim.

    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Jun 1, 2012

    New changeset 24572015e24f by R David Murray in branch '3.2':
    bpo-14957: clarify splitlines docs.
    http://hg.python.org/cpython/rev/24572015e24f

    New changeset 2a43088318ed by R David Murray in branch 'default':
    bpo-14957: clarify splitlines docs.
    http://hg.python.org/cpython/rev/2a43088318ed

    New changeset 0df7594e4ebd by R David Murray in branch '2.7':
    bpo-14957: clarify splitlines docs.
    http://hg.python.org/cpython/rev/0df7594e4ebd

    @bitdancer
    Copy link
    Member

    Thanks. I added an example, too, since split has some.

    @bitdancer bitdancer added the type-bug An unexpected behavior, bug, or error label Jun 1, 2012
    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Jun 2, 2012

    New changeset 4d9b3a58e208 by R David Murray in branch '3.2':
    bpo-14957: fix doc typo.
    http://hg.python.org/cpython/rev/4d9b3a58e208

    New changeset 3bb35ad5d9da by R David Murray in branch 'default':
    bpo-14957: fix doc typo.
    http://hg.python.org/cpython/rev/3bb35ad5d9da

    New changeset 48564362b687 by R David Murray in branch '2.7':
    bpo-14957: fix doc typo.
    http://hg.python.org/cpython/rev/48564362b687

    @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
    docs Documentation in the Doc dir easy type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    3 participants