Skip to content

Commit a7ead2f

Browse files
shveenkovbigbes
authored andcommitted
fix tarantool.connect enable user and password params
1 parent e3ad63a commit a7ead2f

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

tarantool/__init__.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
)
2525

2626

27-
def connect(host="localhost", port=33013):
27+
def connect(host="localhost", port=33013, user=None, password=None):
2828
'''\
2929
Create a connection to the Tarantool server.
3030
@@ -37,8 +37,8 @@ def connect(host="localhost", port=33013):
3737
'''
3838

3939
return Connection(host, port,
40-
user=None,
41-
password=None,
40+
user=user,
41+
password=password,
4242
socket_timeout=SOCKET_TIMEOUT,
4343
reconnect_max_attempts=RECONNECT_MAX_ATTEMPTS,
4444
reconnect_delay=RECONNECT_DELAY,

tests/suites/lib/tarantool_server.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ def wait_until_started(self):
214214
try:
215215
temp = TarantoolAdmin('localhost', self.args['admin'])
216216
ans = temp('box.info.status')[0]
217-
if ans in ('running', 'primary', 'hot_standby', 'orphan') or ans.startswith('replica'):
217+
if ans in ('running', 'primary', 'hot_standby', 'orphan', 'loading') or ans.startswith('replica'):
218218
return True
219219
else:
220220
raise Exception("Strange output for `box.info.status`: %s" % (ans))

0 commit comments

Comments
 (0)