Skip to content

Commit 252ac00

Browse files
authored
Add support for Python 3.12 (#11)
1 parent ffc91a9 commit 252ac00

File tree

4 files changed

+18
-9
lines changed

4 files changed

+18
-9
lines changed

.github/workflows/main.yml

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,13 @@ on:
2222
permissions:
2323
contents: read
2424

25+
env:
26+
FORCE_COLOR: 1
27+
2528
jobs:
2629
tests:
2730
name: "Python ${{ matrix.python-version }}"
28-
# 20.04 because https://github.com/actions/python-versions
29-
# does not have 2.7 and 3.6 binaries for 22.04.
30-
runs-on: "ubuntu-20.04"
31+
runs-on: ${{ matrix.os }}
3132
strategy:
3233
fail-fast: false
3334
matrix:
@@ -38,18 +39,24 @@ jobs:
3839
- "3.8"
3940
- "3.9"
4041
- "3.10"
41-
- "3.11-dev"
42+
- "3.11"
4243
- "pypy-2.7"
4344
- "pypy-3.7"
4445
- "pypy-3.8"
4546
- "pypy-3.9"
47+
# 20.04 because https://github.com/actions/python-versions
48+
# does not have 2.7 and 3.6 binaries for 22.04.
49+
os: ["ubuntu-20.04"]
50+
include:
51+
- { python-version: "3.12", os: "ubuntu-latest" }
4652
steps:
4753
- uses: "actions/checkout@v3"
4854
with:
4955
ref: ${{ inputs.tag || github.ref }}
5056
- uses: "actions/setup-python@v4"
5157
with:
5258
python-version: "${{ matrix.python-version }}"
59+
allow-prereleases: true
5360
cache: "pip"
5461
- name: "Update pip"
5562
run: python -m pip install --upgrade pip setuptools wheel
@@ -68,7 +75,7 @@ jobs:
6875
ref: ${{ inputs.tag || github.ref }}
6976
- uses: "actions/setup-python@v4"
7077
with:
71-
python-version: "3.10"
78+
python-version: "3.x"
7279
cache: "pip"
7380
- name: "Update pip"
7481
run: python -m pip install --upgrade pip setuptools wheel
@@ -77,14 +84,14 @@ jobs:
7784
- name: "Run 'build'"
7885
run: "python -m build"
7986
- name: "Upload sdist artifact"
80-
uses: actions/upload-artifact@v2
87+
uses: actions/upload-artifact@v3
8188
with:
8289
name: sdist
8390
path: |
8491
dist/pyasn1*.tar.gz
8592
if-no-files-found: error
8693
- name: "Upload wheel artifact"
87-
uses: actions/upload-artifact@v2
94+
uses: actions/upload-artifact@v3
8895
with:
8996
name: wheel
9097
path: |

.github/workflows/pypi.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ jobs:
3737
- name: Set up Python 3.10
3838
uses: actions/setup-python@v4
3939
with:
40-
python-version: "3.10"
40+
python-version: "3.x"
4141
- name: "Update pip"
4242
run: python -m pip install --upgrade pip setuptools wheel
4343
- name: "Install 'build' and 'twine'"

setup.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ classifiers =
3636
Programming Language :: Python :: 3.9
3737
Programming Language :: Python :: 3.10
3838
Programming Language :: Python :: 3.11
39+
Programming Language :: Python :: 3.12
3940
Programming Language :: Python :: Implementation :: CPython
4041
Programming Language :: Python :: Implementation :: PyPy
4142
Topic :: Communications

tox.ini

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[tox]
22
minversion = 3.5.0
33
envlist =
4-
py27, py36, py37, py38, py39, py310, py311, pypy27, pypy37, pypy38, pypy39
4+
py27, py36, py37, py38, py39, py310, py311, py312, pypy27, pypy37, pypy38, pypy39
55
cover, bandit, build
66
isolated_build = true
77
skip_missing_interpreters = true
@@ -46,6 +46,7 @@ python =
4646
3.9: py39
4747
3.10: py310, cover, build, bandit
4848
3.11: py311
49+
3.12: py312
4950
pypy-2.7: pypy27
5051
pypy-3.7: pypy37
5152
pypy-3.8: pypy38

0 commit comments

Comments
 (0)