Merge pull request #612 from marc1006/master

Some smaller fixes
pull/618/head
dw 5 years ago committed by GitHub
commit c6de090f08
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -542,7 +542,7 @@ def extend_path(path, name):
if os.path.isfile(pkgfile):
try:
f = open(pkgfile)
except IOError, msg:
except IOError as msg:
sys.stderr.write("Can't open %s: %s\n" %
(pkgfile, msg))
else:

@ -462,7 +462,7 @@ class DefectivePython3xMainMethod(FinderMethod):
return None
path = getattr(mod, '__file__', None)
if not (os.path.exists(path) and _looks_like_script(path)):
if not (path is not None and os.path.exists(path) and _looks_like_script(path)):
return None
fp = open(path, 'rb')

@ -2331,7 +2331,7 @@ class Router(mitogen.core.Router):
directly connected.
"""
stream = self.stream_by_id(context)
if stream.remote_id != context.context_id:
if stream.protocol.remote_id != context.context_id:
return
l = mitogen.core.Latch()

Loading…
Cancel
Save