Repository: nltk/nltk

Issue:
Consider deprecating Python 3.6
Hello!

Python 3.6 is approaching its End Of Life on December 23rd, and we should consider dropping support for Python 3.6 accordingly. In particular, this involves modifying:
* CI tests
* `python_requires` in `setup.py`.
* Lots of documentation throughout the project.

Among other places, I'm sure.

- Tom Aarsen
Add CI tests for Python 3.10
Hello!

Python 3.10 is no longer a glimmer far into the future, and we should start supporting it. The first step in doing so is adding 3.10 to the CI tests, and mentioning that NLTK works for Python 3.10 in our documentation throughout the project.

- Tom Aarsen


Discussion:

Resolving patch:
diff --git a/nltk/__init__.py b/nltk/__init__.py
--- a/nltk/__init__.py
+++ b/nltk/__init__.py
@@ -52,7 +52,7 @@
 # Description of the toolkit, keywords, and the project's primary URL.
 __longdescr__ = """\
 The Natural Language Toolkit (NLTK) is a Python package for
-natural language processing.  NLTK requires Python 3.6, 3.7, 3.8, or 3.9."""
+natural language processing.  NLTK requires Python 3.7, 3.8, 3.9 or 3.10."""
 __keywords__ = [
     "NLP",
     "CL",
@@ -84,10 +84,10 @@
     "Intended Audience :: Science/Research",
     "License :: OSI Approved :: Apache Software License",
     "Operating System :: OS Independent",
-    "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",
     "Topic :: Scientific/Engineering",
     "Topic :: Scientific/Engineering :: Artificial Intelligence",
     "Topic :: Scientific/Engineering :: Human Machine Interfaces",
diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -67,7 +67,7 @@
     },
     long_description="""\
 The Natural Language Toolkit (NLTK) is a Python package for
-natural language processing.  NLTK requires Python 3.6, 3.7, 3.8, or 3.9.""",
+natural language processing.  NLTK requires Python 3.7, 3.8, 3.9 or 3.10.""",
     license="Apache License, Version 2.0",
     keywords=[
         "NLP",
@@ -95,10 +95,10 @@
         "Intended Audience :: Science/Research",
         "License :: OSI Approved :: Apache Software License",
         "Operating System :: OS Independent",
-        "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",
         "Topic :: Scientific/Engineering",
         "Topic :: Scientific/Engineering :: Artificial Intelligence",
         "Topic :: Scientific/Engineering :: Human Machine Interfaces",
@@ -110,7 +110,7 @@
         "Topic :: Text Processing :: Linguistic",
     ],
     package_data={"nltk": ["test/*.doctest", "VERSION"]},
-    python_requires=">=3.6",
+    python_requires=">=3.7",
     install_requires=[
         "click",
         "joblib",


Test patch:
diff --git a/web/dev/local_testing.rst b/web/dev/local_testing.rst
--- a/web/dev/local_testing.rst
+++ b/web/dev/local_testing.rst
@@ -25,10 +25,10 @@ Please consult https://tox.wiki for more info about the tox tool.
 Examples
 --------
 
-Run tests for python 3.6 in verbose mode; executing only tests
+Run tests for python 3.7 in verbose mode; executing only tests
 that failed in the last test run::
 
-    tox -e py36 -- -v --failed
+    tox -e py37 -- -v --failed
 
 Run tree doctests for all available interpreters::
 
@@ -42,7 +42,7 @@ By default, numpy, scipy and scikit-learn are installed in tox virtualenvs.
 This is slow, requires working build toolchain and is not always feasible.
 In order to skip numpy & friends, use ``..-nodeps`` environments::
 
-    tox -e py36-nodeps,py37,pypy
+    tox -e py37-nodeps,py37,pypy
 
 It is also possible to run tests without tox. This way NLTK would be tested
 only under single interpreter, but it may be easier to have numpy and other