From 06bd763bf0fc0f5d1362b98a315722a5dff6febc Mon Sep 17 00:00:00 2001 From: micbou Date: Wed, 25 Apr 2018 00:32:44 +0200 Subject: [PATCH] Increase Python 2 requirement to 2.7.1 Tests are failing on Python 2.7.0 with the exception "TypeError: argument can't be " --- README.md | 2 +- doc/youcompleteme.txt | 2 +- install.py | 8 ++++---- plugin/youcompleteme.vim | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 775cd0b4..4c911221 100644 --- a/README.md +++ b/README.md @@ -2805,7 +2805,7 @@ let g:ycm_disable_for_files_larger_than_kb = 1000 This option specifies the Python interpreter to use to run the [jedi][] completion library. Specify the Python interpreter to use to get completions. By default the Python under which [ycmd][] runs is used ([ycmd][] runs on -Python 2.7 or 3.4+). +Python 2.7.1+ or 3.4+). Default: `''` diff --git a/doc/youcompleteme.txt b/doc/youcompleteme.txt index 7c7f463f..6172835c 100644 --- a/doc/youcompleteme.txt +++ b/doc/youcompleteme.txt @@ -3061,7 +3061,7 @@ The *g:ycm_python_binary_path* option This option specifies the Python interpreter to use to run the jedi [12] completion library. Specify the Python interpreter to use to get completions. By default the Python under which ycmd [47] runs is used (ycmd [47] runs on -Python 2.7 or 3.4+). +Python 2.7.1+ or 3.4+). Default: "''" > diff --git a/install.py b/install.py index 5b77aafe..0783219f 100755 --- a/install.py +++ b/install.py @@ -11,11 +11,11 @@ import sys import os.path as p import glob -PY_MAJOR, PY_MINOR = sys.version_info[ 0 : 2 ] -if not ( ( PY_MAJOR == 2 and PY_MINOR >= 6 ) or - ( PY_MAJOR == 3 and PY_MINOR >= 3 ) or +PY_MAJOR, PY_MINOR, PY_PATCH = sys.version_info[ 0 : 3 ] +if not ( ( PY_MAJOR == 2 and PY_MINOR == 7 and PY_PATCH >= 1 ) or + ( PY_MAJOR == 3 and PY_MINOR >= 4 ) or PY_MAJOR > 3 ): - sys.exit( 'YouCompleteMe requires Python >= 2.6 or >= 3.3; ' + sys.exit( 'YouCompleteMe requires Python >= 2.7.1 or >= 3.4; ' 'your version of Python is ' + sys.version ) DIR_OF_THIS_SCRIPT = p.dirname( p.abspath( __file__ ) ) diff --git a/plugin/youcompleteme.vim b/plugin/youcompleteme.vim index 72c2c2c5..7c1d13a8 100644 --- a/plugin/youcompleteme.vim +++ b/plugin/youcompleteme.vim @@ -57,7 +57,7 @@ elseif !has( 'timers' ) elseif !has( 'python' ) && !has( 'python3' ) echohl WarningMsg | \ echomsg "YouCompleteMe unavailable: requires Vim compiled with " . - \ "Python (2.7 or 3.4+) support." | + \ "Python (2.7.1+ or 3.4+) support." | \ echohl None call s:restore_cpo() finish