Skip to content

Commit 546ec68

Browse files
authored
Add Python 3.14 support (#107)
* Add Python 3.14 support Start testing with Python 3.14 now that it is officially released. Signed-off-by: Eric Brown <eric_wade_brown@yahoo.com> * Update Python version in PR check workflow Signed-off-by: Eric Brown <ericwb@users.noreply.github.com> * Update Python version in GitHub Actions workflow Signed-off-by: Eric Brown <ericwb@users.noreply.github.com> --------- Signed-off-by: Eric Brown <eric_wade_brown@yahoo.com> Signed-off-by: Eric Brown <ericwb@users.noreply.github.com>
1 parent 5f4ff73 commit 546ec68

12 files changed

Lines changed: 290 additions & 251 deletions

File tree

.github/actions/build-vsix/action.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@ runs:
1515
node-version: ${{ inputs.node_version }}
1616
cache: 'npm'
1717

18-
# Minimum supported version is Python 3.9
19-
- name: Use Python 3.9
18+
# Minimum supported version is Python 3.10
19+
- name: Use Python 3.10
2020
uses: actions/setup-python@v5
2121
with:
22-
python-version: '3.9'
22+
python-version: '3.10'
2323

2424
- name: Pip cache
2525
uses: actions/cache@v4

.github/actions/lint/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ runs:
3030
- name: Install Python
3131
uses: actions/setup-python@v5
3232
with:
33-
python-version: '3.9'
33+
python-version: '3.10'
3434

3535
- name: Pip cache
3636
uses: actions/cache@v4

.github/workflows/pr-check.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,19 +45,19 @@ jobs:
4545
fail-fast: false
4646
matrix:
4747
os: [ubuntu-latest, windows-latest, macos-latest]
48-
python: ['3.9', '3.10', '3.11', '3.12', '3.13']
48+
python: ['3.10', '3.11', '3.12', '3.13', '3.14']
4949

5050
steps:
5151
- name: Checkout
5252
uses: actions/checkout@v5
5353
with:
5454
path: ${{ env.special-working-directory-relative }}
5555

56-
# Install bundled libs using 3.9 even though you test it on other versions.
57-
- name: Use Python 3.9
56+
# Install bundled libs using 3.10 even though you test it on other versions.
57+
- name: Use Python 3.10
5858
uses: actions/setup-python@v6
5959
with:
60-
python-version: '3.9'
60+
python-version: '3.10'
6161

6262
- name: Update pip, install wheel and nox
6363
run: python -m pip install -U pip wheel nox
@@ -71,7 +71,7 @@ jobs:
7171
python -m nox --session install_bundled_libs
7272
shell: bash
7373

74-
# Now that the bundle is installed to target using python 3.9
74+
# Now that the bundle is installed to target using python 3.10
7575
# switch back the python we want to test with
7676
- name: Use Python ${{ matrix.python }}
7777
uses: actions/setup-python@v6

.github/workflows/push-check.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -50,19 +50,19 @@ jobs:
5050
fail-fast: false
5151
matrix:
5252
os: [ubuntu-latest, windows-latest, macos-latest]
53-
python: ['3.9', '3.10', '3.11', '3.12', '3.13']
53+
python: [3.10', '3.11', '3.12', '3.13', '3.14']
5454

5555
steps:
5656
- name: Checkout
5757
uses: actions/checkout@v5
5858
with:
5959
path: ${{ env.special-working-directory-relative }}
6060

61-
# Install bundled libs using 3.9 even though you test it on other versions.
62-
- name: Use Python 3.9
61+
# Install bundled libs using 3.10 even though you test it on other versions.
62+
- name: Use Python 3.10
6363
uses: actions/setup-python@v6
6464
with:
65-
python-version: '3.9'
65+
python-version: '3.10'
6666

6767
- name: Update pip, install wheel and nox
6868
run: python -m pip install -U pip wheel nox
@@ -76,7 +76,7 @@ jobs:
7676
python -m nox --session install_bundled_libs
7777
shell: bash
7878

79-
# Now that the bundle is installed to target using python 3.9
79+
# Now that the bundle is installed to target using python 3.10
8080
# switch back the python we want to test with
8181
- name: Use Python ${{ matrix.python }}
8282
uses: actions/setup-python@v6

bundled/tool/lsp_runner.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -35,17 +35,17 @@ def update_sys_path(path_to_add: str, strategy: str) -> None:
3535

3636
RPC = jsonrpc.create_json_rpc(sys.stdin.buffer, sys.stdout.buffer)
3737

38-
EXIT_NOW = False
39-
while not EXIT_NOW:
38+
exit_now = False
39+
while not exit_now:
4040
msg = RPC.receive_data()
4141

4242
method = msg["method"]
4343
if method == "exit":
44-
EXIT_NOW = True
44+
exit_now = True
4545
continue
4646

4747
if method == "run":
48-
IS_EXCEPTION = False
48+
is_exception = False
4949
# This is needed to preserve sys.path, pylint modifies
5050
# sys.path and that might not work for this scenario
5151
# next time around.
@@ -65,12 +65,12 @@ def update_sys_path(path_to_add: str, strategy: str) -> None:
6565
)
6666
except Exception: # pylint: disable=broad-except
6767
result = utils.RunResult("", traceback.format_exc(chain=True))
68-
IS_EXCEPTION = True
68+
is_exception = True
6969

7070
response = {"id": msg["id"]}
7171
if result.stderr:
7272
response["error"] = result.stderr
73-
response["exception"] = IS_EXCEPTION
73+
response["exception"] = is_exception
7474
elif result.stdout:
7575
response["result"] = result.stdout
7676

noxfile.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ def _setup_template_environment(session: nox.Session) -> None:
102102
_install_bundle(session)
103103

104104

105-
@nox.session(python="3.9")
105+
@nox.session(python="3.10")
106106
def install_bundled_libs(session):
107107
"""Installs the libraries that will be bundled with the extension."""
108108
session.install("wheel")

requirements.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# This file is used to generate requirements.txt.
22
# NOTE:
3-
# Use Python 3.9 or greater which ever is the minimum version of the python
3+
# Use Python 3.10 or greater which ever is the minimum version of the python
44
# you plan on supporting when creating the environment or using pip-tools.
55
# Only run the commands below to manully upgrade packages in requirements.txt:
66
# 1) python -m pip install pip-tools
@@ -9,6 +9,6 @@
99
# run the above commands manually.
1010

1111
# Required packages
12-
pygls
12+
pygls==1.3.1
1313
packaging
1414
bandit[sarif]

0 commit comments

Comments
 (0)