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

[Release 1.9] Unsupport targetting 3.7. (#16883) #16900

Merged
merged 1 commit into from
Feb 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion mypy/defaults.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

# Earliest Python 3.x version supported via --python-version 3.x. To run
# mypy, at least version PYTHON3_VERSION is needed.
PYTHON3_VERSION_MIN: Final = (3, 7) # Keep in sync with typeshed's python support
PYTHON3_VERSION_MIN: Final = (3, 8) # Keep in sync with typeshed's python support

CACHE_DIR: Final = ".mypy_cache"
CONFIG_FILE: Final = ["mypy.ini", ".mypy.ini"]
Expand Down
12 changes: 6 additions & 6 deletions test-data/unit/cmdline.test
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,7 @@ main.py:1: error: Cannot find implementation or library stub for module named "a
\[tool.mypy]
python_version = 3.10
[out]
pyproject.toml: [mypy]: python_version: Python 3.1 is not supported (must be 3.7 or higher). You may need to put quotes around your Python version
pyproject.toml: [mypy]: python_version: Python 3.1 is not supported (must be 3.8 or higher). You may need to put quotes around your Python version
== Return code: 0

[case testPythonVersionTooOld10]
Expand All @@ -604,13 +604,13 @@ python_version = 1.0
mypy.ini: [mypy]: python_version: Python major version '1' out of range (must be 3)
== Return code: 0

[case testPythonVersionTooOld36]
[case testPythonVersionTooOld37]
# cmd: mypy -c pass
[file mypy.ini]
\[mypy]
python_version = 3.6
python_version = 3.7
[out]
mypy.ini: [mypy]: python_version: Python 3.6 is not supported (must be 3.7 or higher)
mypy.ini: [mypy]: python_version: Python 3.7 is not supported (must be 3.8 or higher)
== Return code: 0

[case testPythonVersionTooNew40]
Expand All @@ -633,11 +633,11 @@ usage: mypy [-h] [-v] [-V] [more options; see below]
mypy: error: Mypy no longer supports checking Python 2 code. Consider pinning to mypy<0.980 if you need to check Python 2 code.
== Return code: 2

[case testPythonVersionAccepted37]
[case testPythonVersionAccepted38]
# cmd: mypy -c pass
[file mypy.ini]
\[mypy]
python_version = 3.7
python_version = 3.8
[out]

[case testPythonVersionAccepted311]
Expand Down
Loading