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

Don't require win_unicode_console on Python 3.6 #9946

Merged
merged 1 commit into from Sep 13, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions IPython/terminal/interactiveshell.py
Expand Up @@ -340,6 +340,11 @@ def prompt_for_code(self):
return document.text

def enable_win_unicode_console(self):
if sys.version_info >= (3, 6):
# Since PEP 528, Python uses the unicode APIs for the Windows
# console by default, so WUC shouldn't be needed.
return

import win_unicode_console

if PY3:
Expand Down
3 changes: 2 additions & 1 deletion setup.py
Expand Up @@ -218,7 +218,8 @@ def run(self):
':python_version == "2.7" or python_version == "3.3"': ['pathlib2'],
':sys_platform != "win32"': ['pexpect'],
':sys_platform == "darwin"': ['appnope'],
':sys_platform == "win32"': ['colorama', 'win_unicode_console>=0.5'],
':sys_platform == "win32"': ['colorama'],
':sys_platform == "win32" and python_version < "3.6"': ['win_unicode_console>=0.5'],
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This syntax should be valid as of setuptools 17.1, released June 2015. I'm OK with depending on that.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We already have similar ones above, I suspect we already require something similar.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Specifically the < comparison - I believe == and != were supported before other comparsions.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm guessing that since setuptools 17 is more than a year ago, I suspect that most people with setuptools < 17 have setuptools 0.6 + pip 1.5.6, and need to upgrade anyway. I doubt many folks are stuck on setuptools 16.

'test:python_version == "2.7"': ['mock'],
})
# FIXME: re-specify above platform dependencies for pip < 6
Expand Down