mirror of
https://github.com/clearlinux/uwsgi.git
synced 2026-08-19 12:06:36 +00:00
try to load trollius on python2
This commit is contained in:
@@ -328,9 +328,13 @@ static void asyncio_loop() {
|
||||
uwsgi.schedule_fix = uwsgi_asyncio_schedule_fix;
|
||||
}
|
||||
|
||||
#ifndef UWSGI_PYTHREE
|
||||
PyObject *asyncio = PyImport_ImportModule("trollius");
|
||||
#else
|
||||
PyObject *asyncio = PyImport_ImportModule("asyncio");
|
||||
#endif
|
||||
if (!asyncio) uwsgi_pyexit;
|
||||
|
||||
|
||||
uasyncio.mod = asyncio;
|
||||
|
||||
uasyncio.loop = PyObject_CallMethod(asyncio, "get_event_loop", NULL);
|
||||
|
||||
Reference in New Issue
Block a user