Re: [Python-Dev] [Python-checkins] cpython: Issue #12981: rewrite multiprocessing_{sendfd, recvfd} in Python.
2011/9/26 Charles-François Natali : > I'm not sure I understand what you mean. You actually understood what I meant, I was just wrong because I misread the conditional. Nothing to see here, please move along :) Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] [Python-checkins] cpython: Issue #12981: rewrite multiprocessing_{sendfd, recvfd} in Python.
> On Sun, Sep 25, 2011 at 4:04 AM, charles-francois.natali > wrote: >> +if not(sys.platform == 'win32' or (hasattr(socket, 'CMSG_LEN') and >> + hasattr(socket, 'SCM_RIGHTS'))): >> raise ImportError('pickling of connections not supported') > > I'm pretty sure the functionality checks for CMSG_LEN and SCM_RIGHTS > mean the platform check for Windows is now redundant. > I'm not sure I understand what you mean. FD passing is supported on Unix with sendmsg/SCM_RIGHTS, and on Windows using whatever Windows uses for that purpose (see http://hg.python.org/cpython/file/2b47f0146639/Lib/multiprocessing/reduction.py#l63). If we remove the check for Windows, an ImportError will be raised systematically, unless you suggest that Windows does support sendmsg/SCM_RIGHTS (I somehow doubt Windows supports Unix domain sockets, but I don't know Windows at all). cf ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com
Re: [Python-Dev] [Python-checkins] cpython: Issue #12981: rewrite multiprocessing_{sendfd, recvfd} in Python.
On Sun, Sep 25, 2011 at 4:04 AM, charles-francois.natali wrote: > +if not(sys.platform == 'win32' or (hasattr(socket, 'CMSG_LEN') and > + hasattr(socket, 'SCM_RIGHTS'))): > raise ImportError('pickling of connections not supported') I'm pretty sure the functionality checks for CMSG_LEN and SCM_RIGHTS mean the platform check for Windows is now redundant. Cheers, Nick. -- Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia ___ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com