def discover(self, seconds=<NUM_LIT:2>):
log.info("<STR_LIT>")<EOL>with gevent.Timeout(seconds, StopBroadcasting) as timeout:<EOL><INDENT>try:<EOL><INDENT>try:<EOL><INDENT>while True:<EOL><INDENT>self.upnp.broadcast()<EOL>gevent.sleep(<NUM_LIT:1>)<EOL><DEDENT><DEDENT>except Exception as e:<EOL><INDENT>raise StopBroadcasting(e)<EOL><DEDENT><DEDENT>except StopBroadcasting:<EOL><INDENT>return<EOL><DEDENT><DEDENT>
Discover devices in the environment.

@param seconds: Number of seconds to broadcast requests.
@type seconds: int