aboutsummaryrefslogtreecommitdiffstats
path: root/python-twisted/unassembled/Platform.py
diff options
context:
space:
mode:
Diffstat (limited to 'python-twisted/unassembled/Platform.py')
-rw-r--r--python-twisted/unassembled/Platform.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/python-twisted/unassembled/Platform.py b/python-twisted/unassembled/Platform.py
index a9e811b..b220257 100644
--- a/python-twisted/unassembled/Platform.py
+++ b/python-twisted/unassembled/Platform.py
@@ -21,10 +21,9 @@ from twisted.python.compat import (
pnconn_pool = HTTPConnectionPool(reactor, persistent=True)
pnconn_pool.maxPersistentPerHost = 100000
-pnconn_pool.cachedConnectionTimeout = 310
+pnconn_pool.cachedConnectionTimeout = 15
pnconn_pool.retryAutomatically = True
-
class Pubnub(PubnubCoreAsync):
def start(self):
@@ -90,11 +89,11 @@ class Pubnub(PubnubCoreAsync):
def received(response):
if not isinstance(response, twisted.web._newclient.Response):
- _invoke(error, {"message": "Not Found"})
+ _invoke(error, {"message" : "Not Found"})
return
finished = Deferred()
- if response.code in [401, 403]:
+ if response.code in [401,403]:
response.deliverBody(PubNubPamResponse(finished))
else:
response.deliverBody(PubNubResponse(finished))