Move all *support.py modules into support/*.py; fix references
This commit is contained in:
@@ -34,13 +34,13 @@ try:
|
||||
import greenlet
|
||||
except ImportError:
|
||||
try:
|
||||
import pylibsupport
|
||||
pylibsupport.emulate()
|
||||
import support.pylib
|
||||
support.pylib.emulate()
|
||||
greenlet = sys.modules['greenlet']
|
||||
except ImportError:
|
||||
try:
|
||||
import stacklesssupport
|
||||
stacklesssupport.emulate()
|
||||
import support.stackless
|
||||
support.stackless.emulate()
|
||||
greenlet = sys.modules['greenlet']
|
||||
except ImportError:
|
||||
raise ImportError("Unable to find an implementation of greenlet.")
|
||||
|
12
eventlet/support/__init__.py
Normal file
12
eventlet/support/__init__.py
Normal file
@@ -0,0 +1,12 @@
|
||||
#!/usr/bin/python
|
||||
"""\
|
||||
@file __init__.py
|
||||
@author Nat Goodspeed
|
||||
@date 2008-03-18
|
||||
@brief Make eventlet.support a subpackage
|
||||
|
||||
$LicenseInfo:firstyear=2008&license=internal$
|
||||
Copyright (c) 2008, Linden Research, Inc.
|
||||
$/LicenseInfo$
|
||||
"""
|
||||
|
@@ -1,5 +1,5 @@
|
||||
"""\
|
||||
@file pylibsupport.py
|
||||
@file support.pylib.py
|
||||
@author Donovan Preston
|
||||
|
||||
Copyright (c) 2005-2006, Donovan Preston
|
@@ -1,5 +1,5 @@
|
||||
"""\
|
||||
@file twistedsupport.py
|
||||
@file support.twisted.py
|
||||
@author Donovan Preston
|
||||
|
||||
Copyright (c) 2005-2006, Donovan Preston
|
||||
@@ -124,7 +124,7 @@ class EventletReactor(posixbase.PosixReactorBase):
|
||||
|
||||
def emulate():
|
||||
if not _working:
|
||||
raise RuntimeError, "Can't use twistedsupport because zope.interface is not installed."
|
||||
raise RuntimeError, "Can't use support.twisted because zope.interface is not installed."
|
||||
reactor = EventletReactor()
|
||||
from twisted.internet.main import installReactor
|
||||
installReactor(reactor)
|
Reference in New Issue
Block a user