File tree Expand file tree Collapse file tree 3 files changed +7
-5
lines changed Expand file tree Collapse file tree 3 files changed +7
-5
lines changed Original file line number Diff line number Diff line change 11
11
from .middleware import WSGIApp , Middleware
12
12
from .tornado import get_tornado_handler
13
13
if sys .version_info >= (3 , 5 ): # pragma: no cover
14
- # from .asyncio_client import AsyncClient
15
14
from .asyncio_client import AsyncClient
16
15
from .asyncio_server import AsyncServer
17
16
from .asyncio_manager import AsyncManager
18
17
from .asyncio_namespace import AsyncNamespace , AsyncClientNamespace
19
18
from .asyncio_redis_manager import AsyncRedisManager
20
19
from .asgi import ASGIApp
21
20
else : # pragma: no cover
21
+ AsyncClient = None
22
22
AsyncServer = None
23
23
AsyncManager = None
24
24
AsyncNamespace = None
Original file line number Diff line number Diff line change 13
13
14
14
15
15
class AsyncClient (client .Client ):
16
- """An Socket.IO client for asyncio.
16
+ """A Socket.IO client for asyncio.
17
17
18
- This class implements a fully compliant Engine .IO web client with support
18
+ This class implements a fully compliant Socket .IO web client with support
19
19
for websocket and long-polling transports.
20
20
21
21
:param reconnection: ``True`` if the client should automatically attempt to
@@ -110,6 +110,7 @@ async def wait(self):
110
110
"""
111
111
while True :
112
112
await self .eio .wait ()
113
+ await self .sleep (1 ) # give the reconnect task time to start up
113
114
if not self ._reconnect_task :
114
115
break
115
116
await self ._reconnect_task
Original file line number Diff line number Diff line change 13
13
14
14
15
15
class Client (object ):
16
- """An Socket.IO client.
16
+ """A Socket.IO client.
17
17
18
- This class implements a fully compliant Engine .IO web client with support
18
+ This class implements a fully compliant Socket .IO web client with support
19
19
for websocket and long-polling transports.
20
20
21
21
:param reconnection: ``True`` if the client should automatically attempt to
@@ -214,6 +214,7 @@ def wait(self):
214
214
"""
215
215
while True :
216
216
self .eio .wait ()
217
+ self .sleep (1 ) # give the reconnect task time to start up
217
218
if not self ._reconnect_task :
218
219
break
219
220
self ._reconnect_task .join ()
You can’t perform that action at this time.
0 commit comments