Use exception for Timeout, not return value

This commit is contained in:
Brian Warner 2015-11-11 18:01:22 -08:00
parent 6de677c1df
commit cb5ad8ced1

View File

@ -86,7 +86,7 @@ class Channel:
while body is None:
remaining = self._started + self._timeout - time.time()
if remaining < 0:
return Timeout
raise Timeout
queryargs = urlencode([("appid", self._appid),
("channelid", self._channelid)])
f = EventSourceFollower(self._relay_url+"get?%s" % queryargs,