diff --git a/README.rst b/README.rst index 9a67a9f1..89ce88ee 100644 --- a/README.rst +++ b/README.rst @@ -102,7 +102,7 @@ Features and Limitations Jedi's features are listed here: `Features `_. -You can run Jedi on Python 3.6+ but it should also +You can run Jedi on Python 3.8+ but it should also understand code that is older than those versions. Additionally you should be able to use `Virtualenvs `_ very well. diff --git a/docs/docs/features.rst b/docs/docs/features.rst index e7ef6731..72c3bc8a 100644 --- a/docs/docs/features.rst +++ b/docs/docs/features.rst @@ -16,7 +16,7 @@ Jedi's main API calls and features are: Basic Features -------------- -- Python 3.6+ support +- Python 3.8+ support - Ignores syntax errors and wrong indentation - Can deal with complex module / function / class structures - Great ``virtualenv``/``venv`` support diff --git a/jedi/api/environment.py b/jedi/api/environment.py index 64b318e1..d2f7bd29 100644 --- a/jedi/api/environment.py +++ b/jedi/api/environment.py @@ -22,7 +22,7 @@ if TYPE_CHECKING: _VersionInfo = namedtuple('VersionInfo', 'major minor micro') # type: ignore[name-match] -_SUPPORTED_PYTHONS = ['3.13', '3.12', '3.11', '3.10', '3.9', '3.8', '3.7', '3.6'] +_SUPPORTED_PYTHONS = ['3.13', '3.12', '3.11', '3.10', '3.9', '3.8'] _SAFE_PATHS = ['/usr/bin', '/usr/local/bin'] _CONDA_VAR = 'CONDA_PREFIX' _CURRENT_VERSION = '%s.%s' % (sys.version_info.major, sys.version_info.minor) diff --git a/jedi/inference/docstrings.py b/jedi/inference/docstrings.py index 809974f3..8b8f6f1c 100644 --- a/jedi/inference/docstrings.py +++ b/jedi/inference/docstrings.py @@ -109,7 +109,7 @@ def _expand_typestr(type_str): yield type_str.split('of')[0] # Check if type has is a set of valid literal values eg: {'C', 'F', 'A'} elif type_str.startswith('{'): - node = parse(type_str, version='3.7').children[0] + node = parse(type_str, version='3.13').children[0] if node.type == 'atom': for leaf in getattr(node.children[1], "children", []): if leaf.type == 'number': diff --git a/setup.py b/setup.py index 54b5b0a1..cb0f509d 100755 --- a/setup.py +++ b/setup.py @@ -34,7 +34,7 @@ setup(name='jedi', keywords='python completion refactoring vim', long_description=readme, packages=find_packages(exclude=['test', 'test.*']), - python_requires='>=3.6', + python_requires='>=3.8', # Python 3.13 grammars are added to parso in 0.8.4 install_requires=['parso>=0.8.4,<0.9.0'], extras_require={ @@ -94,8 +94,6 @@ setup(name='jedi', 'License :: OSI Approved :: MIT License', 'Operating System :: OS Independent', 'Programming Language :: Python :: 3', - 'Programming Language :: Python :: 3.6', - 'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.8', 'Programming Language :: Python :: 3.9', 'Programming Language :: Python :: 3.10', diff --git a/test/run.py b/test/run.py index 01fe5354..0fd01b23 100755 --- a/test/run.py +++ b/test/run.py @@ -134,7 +134,7 @@ TEST_GOTO = 2 TEST_REFERENCES = 3 -grammar36 = parso.load_grammar(version='3.6') +grammar313 = parso.load_grammar(version='3.13') class BaseTestCase(object): @@ -238,7 +238,7 @@ class IntegrationTestCase(BaseTestCase): should_be = set() for match in re.finditer('(?:[^ ]+)', correct): string = match.group(0) - parser = grammar36.parse(string, start_symbol='eval_input', error_recovery=False) + parser = grammar313.parse(string, start_symbol='eval_input', error_recovery=False) parser_utils.move(parser.get_root_node(), self.line_nr) node = parser.get_root_node() module_context = script._get_module_context() @@ -504,7 +504,7 @@ if __name__ == '__main__': if arguments['--env']: environment = get_system_environment(arguments['--env']) else: - # Will be 3.6. + # Will be 3.13. environment = get_default_environment() import traceback diff --git a/test/test_api/test_environment.py b/test/test_api/test_environment.py index 621fcb8e..ea0c1730 100644 --- a/test/test_api/test_environment.py +++ b/test/test_api/test_environment.py @@ -26,7 +26,7 @@ def test_find_system_environments(): @pytest.mark.parametrize( 'version', - ['3.6', '3.7', '3.8', '3.9'] + ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13'] ) def test_versions(version): try: diff --git a/test/test_utils.py b/test/test_utils.py index 15a79174..4fc19878 100644 --- a/test/test_utils.py +++ b/test/test_utils.py @@ -91,7 +91,7 @@ class TestSetupReadline(unittest.TestCase): } # There are quite a few differences, because both Windows and Linux # (posix and nt) libraries are included. - assert len(difference) < 30 + assert len(difference) < 40 def test_local_import(self): s = 'import test.test_utils'