diff --git a/conftest.py b/conftest.py
index 28a04e74..d4aaae42 100644
--- a/conftest.py
+++ b/conftest.py
@@ -144,14 +144,6 @@ def jedi_path():
return os.path.dirname(__file__)
-@pytest.fixture()
-def skip_python2(environment):
- if environment.version_info.major == 2:
- # This if is just needed to avoid that tests ever skip way more than
- # they should for all Python versions.
- pytest.skip()
-
-
@pytest.fixture()
def skip_pre_python38(environment):
if environment.version_info < (3, 8):
diff --git a/docs/docs/installation.rst b/docs/docs/installation.rst
index 46e5ba90..d8df120c 100644
--- a/docs/docs/installation.rst
+++ b/docs/docs/installation.rst
@@ -50,14 +50,6 @@ Arch Linux
You can install |jedi| directly from official Arch Linux packages:
- `python-jedi `__
- (Python 3)
-- `python2-jedi `__
- (Python 2)
-
-The specified Python version just refers to the *runtime environment* for
-|jedi|. Use the Python 2 version if you're running vim (or whatever editor you
-use) under Python 2. Otherwise, use the Python 3 version. But whatever version
-you choose, both are able to complete both Python 2 and 3 *code*.
(There is also a packaged version of the vim plugin available:
`vim-jedi at Arch Linux `__.)
diff --git a/jedi/api/classes.py b/jedi/api/classes.py
index 7c527128..0ba7c3b7 100644
--- a/jedi/api/classes.py
+++ b/jedi/api/classes.py
@@ -336,7 +336,7 @@ class BaseName(object):
>>> print(defs) # doctest: +NORMALIZE_WHITESPACE
[,
]
- >>> str(defs[0].description) # strip literals in python2
+ >>> str(defs[0].description)
'def f'
>>> str(defs[1].description)
'class C'
diff --git a/test/test_api/test_call_signatures.py b/test/test_api/test_call_signatures.py
index 5b4e9033..3f305cb4 100644
--- a/test/test_api/test_call_signatures.py
+++ b/test/test_api/test_call_signatures.py
@@ -503,7 +503,7 @@ _calls = [
@pytest.mark.parametrize('ending', ['', ')'])
@pytest.mark.parametrize('code, call, expected_index', _calls)
-def test_signature_index(skip_python2, Script, environment, code, call, expected_index, ending):
+def test_signature_index(Script, environment, code, call, expected_index, ending):
if isinstance(expected_index, tuple):
expected_index = expected_index[environment.version_info > (3, 8)]
if environment.version_info < (3, 8):
diff --git a/test/test_api/test_documentation.py b/test/test_api/test_documentation.py
index 1fe8bfd9..104555cd 100644
--- a/test/test_api/test_documentation.py
+++ b/test/test_api/test_documentation.py
@@ -91,7 +91,7 @@ def test_version_info(Script):
assert c.docstring() == 'sys.version_info\n\nVersion information as a named tuple.'
-def test_builtin_docstring(goto_or_help_or_infer, skip_python2):
+def test_builtin_docstring(goto_or_help_or_infer):
d, = goto_or_help_or_infer('open')
doc = d.docstring()
@@ -99,7 +99,7 @@ def test_builtin_docstring(goto_or_help_or_infer, skip_python2):
assert 'Open file' in doc
-def test_docstring_decorator(goto_or_help_or_infer, skip_python2):
+def test_docstring_decorator(goto_or_help_or_infer):
code = dedent('''
import types
diff --git a/test/test_api/test_signatures.py b/test/test_api/test_signatures.py
index 0fe6d408..a211c1e3 100644
--- a/test/test_api/test_signatures.py
+++ b/test/test_api/test_signatures.py
@@ -1,5 +1,3 @@
-import sys
-
import pytest
_tuple_code = 'from typing import Tuple\ndef f(x: Tuple[int]): ...\nf'
@@ -20,7 +18,7 @@ _tuple_code = 'from typing import Tuple\ndef f(x: Tuple[int]): ...\nf'
('def f(*args: int, **kwargs: str): ...\nf', ['class int', 'class str'], False),
]
)
-def test_param_annotation(Script, code, expected_params, execute_annotation, skip_python2):
+def test_param_annotation(Script, code, expected_params, execute_annotation):
func, = Script(code).goto()
sig, = func.get_signatures()
for p, expected in zip(sig.params, expected_params):
@@ -60,7 +58,7 @@ def test_param_default(Script, code, expected_params):
('def f(*args, x): pass\nf', 1, 'x', 'KEYWORD_ONLY'),
]
)
-def test_param_kind_and_name(code, index, param_code, kind, Script, skip_python2):
+def test_param_kind_and_name(code, index, param_code, kind, Script):
func, = Script(code).goto()
sig, = func.get_signatures()
param = sig.params[index]
diff --git a/test/test_inference/test_gradual/test_typeshed.py b/test/test_inference/test_gradual/test_typeshed.py
index 73c9d194..1130a2b2 100644
--- a/test/test_inference/test_gradual/test_typeshed.py
+++ b/test/test_inference/test_gradual/test_typeshed.py
@@ -126,7 +126,7 @@ def test_math(Script):
assert value
-def test_type_var(Script, skip_python2):
+def test_type_var(Script):
def_, = Script('import typing; T = typing.TypeVar("T1")').infer()
assert def_.name == 'TypeVar'
assert def_.description == 'class TypeVar'
diff --git a/test/test_inference/test_imports.py b/test/test_inference/test_imports.py
index ee216ac7..88dde53a 100644
--- a/test/test_inference/test_imports.py
+++ b/test/test_inference/test_imports.py
@@ -85,7 +85,7 @@ def test_find_module_package_zipped(Script, inference_state, environment):
)
def test_correct_zip_package_behavior(Script, inference_state, environment, code,
- file, package, path, skip_python2):
+ file, package, path):
sys_path = environment.get_sys_path() + [pkg_zip_path]
pkg, = Script(code, project=Project('.', sys_path=sys_path)).infer()
value, = pkg._name.infer()
diff --git a/test/test_inference/test_literals.py b/test/test_inference/test_literals.py
index 42305d72..f63b616f 100644
--- a/test/test_inference/test_literals.py
+++ b/test/test_inference/test_literals.py
@@ -26,7 +26,7 @@ def test_f_strings(Script, environment):
assert _infer_literal(Script, 'rF"{asdf} "', is_fstring=True) == ''
-def test_rb_strings(Script, environment, skip_python2):
+def test_rb_strings(Script, environment):
assert _infer_literal(Script, 'x = br"asdf"; x') == b'asdf'
assert _infer_literal(Script, 'x = rb"asdf"; x') == b'asdf'