Closed viniciusjarina closed 9 years ago
@navarr ping
@viniciusjarina
Before I merge this - is there any benefit to having the timeout be a parameter instead of a configuration attribute on the class itself?
I say this because you're passing it around multiple functions through run() which means for the average use case it's only set once per implementation - in which case it would probably be better for it to be an attribute.
Thoughts?
Is up to you. :smile:
I think as parameter of run is quite straight forward. Since the run method block the execution, is a common pattern to have a timeout parameter of blocking functions (even in other languages like C#).
I refactored it into a configuration parameter (I think it looks cleaner - sorry about that).
Thank you very much for the code. You've been working harder on this project lately than I have. I imagine you're using it for something? Anything interesting?
I am using to do interop between PHP and Python :wink:
I have a library in PHP that I want to use from Python, so I've wrote a PHP server to do the calls and a client interface from Python. ;)
Neat! Thank you as always for pushing your changes and tweaks upstream :)
No problem :)
On Mon, Feb 23, 2015 at 2:15 PM, Navarr Barnier notifications@github.com wrote:
Neat! Thank you as always for pushing your changes and tweaks upstream :)
— Reply to this email directly or view it on GitHub https://github.com/navarr/Sockets/pull/8#issuecomment-75586752.
Used internally by the socket_select