simplify internal plugin dispatching code, rename parts of the py._com plugin helpers
--HG-- branch : 1.0.x
This commit is contained in:
@@ -88,8 +88,8 @@ class Gateway(object):
|
||||
self._channelfactory = ChannelFactory(self, _startcount)
|
||||
self._cleanup.register(self)
|
||||
if _startcount == 1: # only import 'py' on the "client" side
|
||||
from py._com import Hooks
|
||||
self.hook = Hooks(ExecnetAPI)
|
||||
import py
|
||||
self.hook = py._com.HookRelay(ExecnetAPI, py._com.comregistry)
|
||||
else:
|
||||
self.hook = ExecnetAPI()
|
||||
|
||||
|
||||
@@ -21,7 +21,8 @@ class GatewayManager:
|
||||
if not spec.chdir and not spec.popen:
|
||||
spec.chdir = defaultchdir
|
||||
self.specs.append(spec)
|
||||
self.hook = py._com.Hooks(py.execnet._HookSpecs)
|
||||
self.hook = py._com.HookRelay(
|
||||
py.execnet._HookSpecs, py._com.comregistry)
|
||||
|
||||
def makegateways(self):
|
||||
assert not self.gateways
|
||||
|
||||
Reference in New Issue
Block a user