Skip to content
Snippets Groups Projects
Commit 83cd7a90 authored by Piotr Maślanka's avatar Piotr Maślanka
Browse files

connection-making fixed

parent 51c37cb7
No related branches found
No related tags found
No related merge requests found
...@@ -13,6 +13,7 @@ tmp/ ...@@ -13,6 +13,7 @@ tmp/
*.bak *.bak
*.swp *.swp
*~.nib *~.nib
.idea/
local.properties local.properties
.classpath .classpath
.settings/ .settings/
......
...@@ -64,7 +64,14 @@ class DatabaseDefinition(object): ...@@ -64,7 +64,14 @@ class DatabaseDefinition(object):
def get_connection(self): def get_connection(self):
"""Returns a new connection object. This connects to the database with according """Returns a new connection object. This connects to the database with according
definitions from L{DatabaseDefinition} passed at constructor.""" definitions from L{DatabaseDefinition} passed at constructor."""
c = self.conn_lambda() while True:
try:
c = self.conn_lambda()
except:
import time
time.sleep(5)
else:
break
self.acs(c) self.acs(c)
return c return c
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment