dpallot / simple-websocket-server

A python based websocket server that is simple and easy to use.
950 stars 320 forks source link

SimpleWebSocketServer: honor selectInterval=0 #82

Closed belm0 closed 5 years ago

belm0 commented 6 years ago

Currently for selectInterval=0 case, SimpleWebSocketServer removes the argument completely from the select() call, which means "no timeout". For wrapping SimpleWebSocketServer in an async library, it's useful to support a timeout of 0 so that select returns immediately.

The cited behavior has been removed, so that selectInterval=0 and selectInterval=None are passed as-is to select(). The default value of .1 seconds is unchanged.