Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Bower components Debian packages RPM packages NuGet packages

hemamaps / billiard   python

Repository URL to install this package:

Version: 3.3.0.23 

/ connection.py

from __future__ import absolute_import

import sys

is_pypy = hasattr(sys, 'pypy_version_info')

if sys.version_info[0] == 3:
    from .py3 import connection
else:
    from .py2 import connection  # noqa


if is_pypy:
    import _multiprocessing
    from .compat import setblocking, send_offset

    class Connection(_multiprocessing.Connection):

        def send_offset(self, buf, offset):
            return send_offset(self.fileno(), buf, offset)

        def setblocking(self, blocking):
            setblocking(self.fileno(), blocking)
    _multiprocessing.Connection = Connection


sys.modules[__name__] = connection