Skip to content

Python 3.10 support #432

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

Merged
merged 1 commit into from
Aug 7, 2021
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 .flake8
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[flake8]
filename = *.py,*.pyx,*.pxd,*.pxi,*.pyi
filename = *.py,*.pyi
ignore = E402,E731,D100,D101,D102,D103,D104,D105,W503,W504,E252
exclude = .git,__pycache__,build,dist,.eggs,postgres,vendor

Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,27 +14,27 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
python-version: [3.7, 3.8, 3.9]
python-version: [3.7, 3.8, 3.9, 3.10.0-rc.1]

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI: '3.10.0-rc - 3.10' also works and ensures that GitHub Actions uses the latest version

os: [ubuntu-latest, macos-latest]

steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v2
with:
fetch-depth: 50
submodules: true

- name: Check if release PR.
uses: edgedb/action-release/validate-pr@master
continue-on-error: true
id: release
with:
github_token: ${{ secrets.RELEASE_BOT_GITHUB_TOKEN }}
missing_version_ok: yes
version_file: uvloop/_version.py
version_line_pattern: |
__version__\s*=\s*(?:['"])([[:PEP440:]])(?:['"])

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
uses: actions/setup-python@v2
if: steps.release.outputs.version == 0
with:
python-version: ${{ matrix.python-version }}
Expand All @@ -60,7 +60,7 @@ jobs:
regression-tests:
name: "Regression Tests"
needs: [test]
runs-on: ubuntu-20.04
runs-on: ubuntu-latest

steps:
- run: echo OK
19 changes: 12 additions & 7 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,22 @@

import alabaster
import os
import re
import sys

sys.path.insert(0, os.path.abspath('..'))

with open(os.path.abspath('../setup.py'), 'rt') as f:
_m = re.search(r'''VERSION\s*=\s*(?P<q>'|")(?P<ver>[\d\.]+)(?P=q)''',
f.read())
if not _m:
raise RuntimeError('unable to read the version from setup.py')
version = _m.group('ver')
version_file = os.path.join(os.path.dirname(os.path.dirname(__file__)),
'uvloop', '_version.py')

with open(version_file, 'r') as f:
for line in f:
if line.startswith('__version__ ='):
_, _, version = line.partition('=')
version = version.strip(" \n'\"")
break
else:
raise RuntimeError(
'unable to read the version from uvloop/_version.py')


# -- General configuration ------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion pytest.ini
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[pytest]
addopts = --capture=no --assert=plain --strict --tb native
addopts = --capture=no --assert=plain --strict-markers --tb native
testpaths = tests
filterwarnings = default
11 changes: 6 additions & 5 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,18 +29,18 @@
# their combination breaks too often
# (example breakage: https://gitlab.com/pycqa/flake8/issues/427)
'aiohttp',
'flake8~=3.8.4',
'flake8~=3.9.2',
'psutil',
'pycodestyle~=2.6.0',
'pycodestyle~=2.7.0',
'pyOpenSSL~=19.0.0',
'mypy>=0.800',
]

# Dependencies required to build documentation.
DOC_DEPENDENCIES = [
'Sphinx~=1.7.3',
'sphinxcontrib-asyncio~=0.2.0',
'sphinx_rtd_theme~=0.2.4',
'Sphinx~=4.1.2',
'sphinxcontrib-asyncio~=0.3.0',
'sphinx_rtd_theme~=0.5.2',
]

EXTRA_DEPENDENCIES = {
Expand Down Expand Up @@ -311,6 +311,7 @@ def build_extensions(self):
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'License :: OSI Approved :: Apache Software License',
'License :: OSI Approved :: MIT License',
'Intended Audience :: Developers',
Expand Down