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

bpo-33684: json.tool: Use utf-8 for infile and outfile. #17460

Merged
merged 4 commits into from Dec 4, 2019

Conversation

@methane
Copy link
Member

methane commented Dec 4, 2019

@methane

This comment has been minimized.

Copy link
Member Author

methane commented Dec 4, 2019

I confirmed that Windows CI fails on this test.

======================================================================
FAIL: test_non_ascii_infile (test.test_json.test_tool.TestTool)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "d:\a\1\s\lib\test\test_json\test_tool.py", line 115, in test_non_ascii_infile
    rc, out, err = assert_python_ok('-m', 'json.tool', infile)
  File "d:\a\1\s\lib\test\support\script_helper.py", line 157, in assert_python_ok
    return _assert_python(True, *args, **env_vars)
  File "d:\a\1\s\lib\test\support\script_helper.py", line 143, in _assert_python
    res.fail(cmd_line)
  File "d:\a\1\s\lib\test\support\script_helper.py", line 70, in fail
    raise AssertionError("Process return code is %d\n"
AssertionError: Process return code is 1
command line: ['d:\\a\\1\\s\\PCbuild\\win32\\python.exe', '-X', 'faulthandler', '-I', '-m', 'json.tool', '@test_4856_tmp']

stdout:
---

---

stderr:
---
'charmap' codec can't decode byte 0x81 in position 10: character maps to <undefined>
---
@methane methane force-pushed the methane:json-tool-utf8 branch from 3550574 to e1bef13 Dec 4, 2019
@methane methane merged commit 808769f into python:master Dec 4, 2019
4 checks passed
4 checks passed
Azure Pipelines PR #20191204.10 succeeded
Details
bedevere/issue-number Issue number 33684 found
Details
bedevere/news News entry found in Misc/NEWS.d
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@methane methane deleted the methane:json-tool-utf8 branch Dec 4, 2019
@miss-islington

This comment has been minimized.

Copy link

miss-islington commented Dec 4, 2019

Thanks @methane for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7, 3.8.
🐍🍒🤖 I'm not a witch! I'm not a witch!

miss-islington added a commit to miss-islington/cpython that referenced this pull request Dec 4, 2019
(cherry picked from commit 808769f)

Co-authored-by: Inada Naoki <songofacandy@gmail.com>
@bedevere-bot

This comment has been minimized.

Copy link

bedevere-bot commented Dec 4, 2019

GH-17464 is a backport of this pull request to the 3.8 branch.

@miss-islington

This comment has been minimized.

Copy link

miss-islington commented Dec 4, 2019

Sorry, @methane, I could not cleanly backport this to 3.7 due to a conflict.
Please backport using cherry_picker on command line.
cherry_picker 808769f3a4cbdc47cf1a5708dd61b1787bb192d4 3.7

miss-islington added a commit that referenced this pull request Dec 4, 2019
(cherry picked from commit 808769f)

Co-authored-by: Inada Naoki <songofacandy@gmail.com>
@bedevere-bot

This comment has been minimized.

Copy link

bedevere-bot commented Dec 4, 2019

GH-17465 is a backport of this pull request to the 3.7 branch.

methane added a commit that referenced this pull request Dec 4, 2019
(cherry picked from commit 808769f)

Co-authored-by: Inada Naoki <songofacandy@gmail.com>
jacobneiltaylor added a commit to jacobneiltaylor/cpython that referenced this pull request Dec 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.