From 73a880f76a312f2438859cfec614b202de0fe325 Mon Sep 17 00:00:00 2001 From: Noorhteen Raja NJ Date: Tue, 26 Apr 2022 18:30:31 +0530 Subject: [PATCH] chore: drop py3.7 (#4770) --- .github/workflows/test.yml | 2 +- news/refactor-drop-py37.rst | 23 +++++++++++++++++++++++ setup.py | 2 +- xonsh/lexer.py | 5 ----- 4 files changed, 25 insertions(+), 7 deletions(-) create mode 100644 news/refactor-drop-py37.rst diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 1689baade..73a2f68d5 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -25,7 +25,7 @@ jobs: fail-fast: false matrix: os: [ ubuntu-latest, macOS-latest, windows-latest ] - python-version: [ "3.7", "3.8", "3.9","3.10" ] + python-version: [ "3.8", "3.9","3.10" ] name: Test Python ${{ matrix.python-version }} ${{ matrix.os }} steps: - uses: actions/checkout@v2 diff --git a/news/refactor-drop-py37.rst b/news/refactor-drop-py37.rst new file mode 100644 index 000000000..979cfbd65 --- /dev/null +++ b/news/refactor-drop-py37.rst @@ -0,0 +1,23 @@ +**Added:** + +* + +**Changed:** + +* + +**Deprecated:** + +* + +**Removed:** + +* Removed Python 3.7 support following `NEP0029 `_ + +**Fixed:** + +* + +**Security:** + +* diff --git a/setup.py b/setup.py index 72837f3dd..327cdd133 100755 --- a/setup.py +++ b/setup.py @@ -383,7 +383,7 @@ def main(): "gnureadline; platform_system=='Darwin'", ], } - skw["python_requires"] = ">=3.7" + skw["python_requires"] = ">=3.8" setup(**skw) diff --git a/xonsh/lexer.py b/xonsh/lexer.py index 11066b0ab..7a1123da4 100644 --- a/xonsh/lexer.py +++ b/xonsh/lexer.py @@ -108,11 +108,6 @@ def token_map(): tm[NEWLINE] = "NEWLINE" tm[INDENT] = "INDENT" tm[DEDENT] = "DEDENT" - if PYTHON_VERSION_INFO < (3, 7, 0): - from xonsh.tokenize import ASYNC, AWAIT - - tm[ASYNC] = "ASYNC" - tm[AWAIT] = "AWAIT" if HAS_WALRUS: tm[(OP, ":=")] = "COLONEQUAL" # python 3.10 (backwards and name token compatible) tokens