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

Drop support for Python 3.6, support Python 3.10 #2920

Merged
merged 3 commits into from Dec 21, 2021

Conversation

tomaarsen
Copy link
Member

@tomaarsen tomaarsen commented Dec 19, 2021

Closes #2912, closes #2913

Hello!

Pull request overview

  • Set python_requires in setup.py to >=3.7 instead of >=3.6.
  • Removed mention of supporting Python 3.6 in documentation.
  • Mention support for Python 3.10 in documentation.
  • Removed py36 tests in tox, and add py310 tests.

Note

I left mentions of Python 3.6 in the tools folder, e.g. in run_doctests.py:

for root, dirs, filenames in os.walk('.'):
for filename in filenames:
if filename.endswith('.py'):
path = os.path.join(root, filename)
for pyver in ["python3.5", "python3.6", "python3.7"]:
print(pyver, filename, file=sys.stderr)
subprocess.call([pyver, "-m", "doctest", path])

This folder seems mostly outdated and unused, also containing references back to jenkins and travis. One of the files, run_doctests.py, is not the proper way that doctests should be ran regardless. I didn't worry about these cases too much.

Thanks to @purificant for the commit of his I borrowed from his Python 3.10 branch :)

We should prepare a release soon.

  • Tom Aarsen

@tomaarsen
Copy link
Member Author

This PR is now planned to be merged after the upcoming NLTK release (3.6.6), allowing existing Python 3.6 users to benefit from our changes over the past months.

@stevenbird stevenbird merged commit dd1494e into nltk:develop Dec 21, 2021
@stevenbird
Copy link
Member

Merged, now that 3.6.6 is released.

@stevenbird
Copy link
Member

Thanks @tomaarsen, @purificant

@tomaarsen tomaarsen deleted the deprecate/python-3.6 branch December 21, 2021 07:27
@tomaarsen
Copy link
Member Author

Weirdly enough - these tests passed, but every single CI run after this PR fails to build scikit-learn on Windows. I've removed CI tests for Windows 10 for now, until scikit-learn 1.0.2 releases (planned in middle December 2021), which supposedly adds support for Python 3.10 in Windows.

ExplorerFreda added a commit to ExplorerFreda/nltk that referenced this pull request Dec 24, 2021
…develop

* 'develop' of https://github.com/ExplorerFreda/nltk:
  Temporarily pause Python 3.10 CI tests due to scikit-learn issues with Windows
  Resolve IndexError in `sent_tokenize` (nltk#2922)
  Drop support for Python 3.6, support Python 3.10 (nltk#2920)
  updates for 3.6.6
  minor clean ups
  updates for 3.6.6
tomaarsen added a commit that referenced this pull request Dec 28, 2021
…2920)"

This reverts commit dd1494e.

Considering NLTK 3.6.6 contains a bug, we would rather still allow Python 3.6 to upgrade to NLTK 3.6.7 to resolve this bug.
tomaarsen added a commit that referenced this pull request Dec 28, 2021
This reverts commit 0b8c2d5.
This was reverted initially to allow Python 3.6 users to use NLTK 3.6.7,
which contains a bug-fix for NLTK 3.6.6.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add CI tests for Python 3.10 Consider deprecating Python 3.6
3 participants