File tree 2 files changed +13
-1
lines changed
2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change 22
22
raise RuntimeError ('uvloop requires Python 3.5 or 3.6b3 or greater' )
23
23
24
24
25
- VERSION = '0.9.2.dev0'
26
25
CFLAGS = ['-O2' ]
27
26
LIBUV_DIR = os .path .join (os .path .dirname (__file__ ), 'vendor' , 'libuv' )
28
27
LIBUV_BUILD_DIR = os .path .join (os .path .dirname (__file__ ), 'build' , 'libuv' )
@@ -211,6 +210,18 @@ def build_extensions(self):
211
210
readme = f .read ()
212
211
213
212
213
+ with open (os .path .join (
214
+ os .path .dirname (__file__ ), 'uvloop' , '__init__.py' )) as f :
215
+ for line in f :
216
+ if line .startswith ('__version__ =' ):
217
+ _ , _ , version = line .partition ('=' )
218
+ VERSION = version .strip (" \n '\" " )
219
+ break
220
+ else :
221
+ raise RuntimeError (
222
+ 'unable to read the version from uvloop/__init__.py' )
223
+
224
+
214
225
setup (
215
226
name = 'uvloop' ,
216
227
description = 'Fast implementation of asyncio event loop on top of libuv' ,
Original file line number Diff line number Diff line change 7
7
from .loop import Loop as __BaseLoop # NOQA
8
8
9
9
10
+ __version__ = '0.9.2.dev0'
10
11
__all__ = ('new_event_loop' , 'EventLoopPolicy' )
11
12
12
13
You can’t perform that action at this time.
0 commit comments