Skip to content

Commit 976d889

Browse files
committed
Require Python 3.5 or greater
1 parent e2fe5ec commit 976d889

File tree

1 file changed

+15
-7
lines changed

1 file changed

+15
-7
lines changed

setup.py

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,24 @@
55
# the Apache 2.0 License: http://www.apache.org/licenses/LICENSE-2.0
66

77

8-
from setuptools import setup, Extension
8+
import setuptools
9+
import sys
910

1011

11-
setup(
12+
if sys.version_info < (3, 5):
13+
raise RuntimeError('asyncpg requires Python 3.5 or greater')
14+
15+
16+
setuptools.setup(
1217
name='asyncpg',
1318
version='0.0.1',
1419
description='An asyncio PosgtreSQL driver',
1520
classifiers=[
1621
'License :: OSI Approved :: MIT License',
1722
'Intended Audience :: Developers',
18-
'Programming Language :: Python :: 3',
23+
'Programming Language :: Python :: 3 :: Only',
24+
'Programming Language :: Python :: 3.5',
25+
'Programming Language :: Python :: 3.6',
1926
'Operating System :: POSIX',
2027
'Operating System :: MacOS :: MacOS X',
2128
'Development Status :: 4 - Beta',
@@ -28,9 +35,10 @@
2835
provides=['asyncpg'],
2936
include_package_data=True,
3037
ext_modules=[
31-
Extension("asyncpg.protocol.protocol",
32-
["asyncpg/protocol/record/recordobj.c",
33-
"asyncpg/protocol/protocol.c"],
34-
extra_compile_args=['-O2'])
38+
setuptools.Extension(
39+
"asyncpg.protocol.protocol",
40+
["asyncpg/protocol/record/recordobj.c",
41+
"asyncpg/protocol/protocol.c"],
42+
extra_compile_args=['-O2'])
3543
]
3644
)

0 commit comments

Comments
 (0)