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

Trailing spaces in pretty-printed JSON #60680

Closed
leoliu mannequin opened this issue Nov 15, 2012 · 4 comments
Closed

Trailing spaces in pretty-printed JSON #60680

leoliu mannequin opened this issue Nov 15, 2012 · 4 comments
Assignees
Labels
stdlib Python modules in the Lib dir type-bug An unexpected behavior, bug, or error

Comments

@leoliu
Copy link
Mannequin

leoliu mannequin commented Nov 15, 2012

BPO 16476
Nosy @ezio-melotti
Superseder
  • bpo-16333: Trailing whitespace in json dump when using indent
  • 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 = 'https://github.com/ezio-melotti'
    closed_at = <Date 2012-11-29.00:35:48.093>
    created_at = <Date 2012-11-15.11:15:36.471>
    labels = ['type-bug', 'library']
    title = 'Trailing spaces in pretty-printed JSON'
    updated_at = <Date 2012-11-29.00:35:48.092>
    user = 'https://bugs.python.org/leoliu'

    bugs.python.org fields:

    activity = <Date 2012-11-29.00:35:48.092>
    actor = 'ezio.melotti'
    assignee = 'ezio.melotti'
    closed = True
    closed_date = <Date 2012-11-29.00:35:48.093>
    closer = 'ezio.melotti'
    components = ['Library (Lib)']
    creation = <Date 2012-11-15.11:15:36.471>
    creator = 'leoliu'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 16476
    keywords = []
    message_count = 4.0
    messages = ['175607', '175608', '176593', '176595']
    nosy_count = 3.0
    nosy_names = ['ezio.melotti', 'python-dev', 'leoliu']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = '16333'
    type = 'behavior'
    url = 'https://bugs.python.org/issue16476'
    versions = ['Python 2.7', 'Python 3.2', 'Python 3.3', 'Python 3.4']

    @leoliu
    Copy link
    Mannequin Author

    leoliu mannequin commented Nov 15, 2012

    python -mjson.tool some_file.json > x.json

    x.json will have trailing white spaces.

    Also reported here: http://thread.gmane.org/gmane.comp.python.devel/135311

    @leoliu leoliu mannequin added the type-bug An unexpected behavior, bug, or error label Nov 15, 2012
    @ezio-melotti
    Copy link
    Member

    This is a duplicate of bpo-16333.

    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented Nov 29, 2012

    New changeset fa277ab588de by Ezio Melotti in branch '2.7':
    bpo-16476: Fix json.tool to avoid including trailing whitespace.
    http://hg.python.org/cpython/rev/fa277ab588de

    New changeset 6996a53f13ce by Ezio Melotti in branch '3.2':
    bpo-16476: Fix json.tool to avoid including trailing whitespace.
    http://hg.python.org/cpython/rev/6996a53f13ce

    New changeset 73a7e6ecd0e1 by Ezio Melotti in branch '3.3':
    bpo-16476: merge with 3.2.
    http://hg.python.org/cpython/rev/73a7e6ecd0e1

    New changeset c062ef6e4c3e by Ezio Melotti in branch 'default':
    bpo-16476: null merge with 3.3.
    http://hg.python.org/cpython/rev/c062ef6e4c3e

    @ezio-melotti
    Copy link
    Member

    I fixed this separately from bpo-16333.
    In the "default" branch this got fixed by bpo-16333 already.
    Thanks for the report!

    @ezio-melotti ezio-melotti added the stdlib Python modules in the Lib dir label Nov 29, 2012
    @ezio-melotti ezio-melotti self-assigned this Nov 29, 2012
    @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
    stdlib Python modules in the Lib dir type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant