Author mdk
Recipients mdk, tokibito
Date 2016-11-17.23:02:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1479423740.92.0.896470735443.issue28724@psf.upfronthosting.co.za>
In-reply-to
Content
Hi, thanks for your contribution!

Documentation give examples implementation of your methods:

 - https://docs.python.org/3/library/socket.html#socket.socket.sendmsg 
 - https://docs.python.org/3/library/socket.html#socket.socket.recvmsg

and from here, some remarks:

 - Why allowing people to mix fds and file objects? I'm not a fan of this: I prefer the clarity of allowing only file descriptors. Have you seen such methods (allowing both fd and file obj) in the stdlib?
 - The documented implementation for recv_io checks for integer truncation, there may be a good reason, should'n you do the same?
 - The documented implementation allows to pass a message, shouldn't you at least allow for an optional message to be passed?

Adding those methods may make sense if people are copying send_fds/recv_fds in their code, but I found only two copy/paste in github, so I think the best is to put your code as a module on pypi and see, from here, if it gets popular?

You should also write a few tests, and comply to the PEP8 (your two methods should probably be separated by a newline).

Bests
History
Date User Action Args
2016-11-17 23:02:20mdksetrecipients: + mdk, tokibito
2016-11-17 23:02:20mdksetmessageid: <1479423740.92.0.896470735443.issue28724@psf.upfronthosting.co.za>
2016-11-17 23:02:20mdklinkissue28724 messages
2016-11-17 23:02:20mdkcreate