mirror of
https://github.com/bigchaindb/bigchaindb.git
synced 2024-10-13 13:34:05 +00:00
Add artificial delay to wait for tables init
This commit is contained in:
parent
9d04018533
commit
70b86ce49b
@ -2,7 +2,7 @@
|
||||
for ``argparse.ArgumentParser``.
|
||||
"""
|
||||
|
||||
import os
|
||||
import time
|
||||
import argparse
|
||||
import multiprocessing as mp
|
||||
import subprocess
|
||||
@ -20,6 +20,10 @@ def start_rethinkdb():
|
||||
|
||||
for line in proc.stdout:
|
||||
if line.startswith('Server ready'):
|
||||
# FIXME: seems like tables are not ready when the server is ready,
|
||||
# that's why we need to sleep a bit before returning.
|
||||
# Not the optimal solution. Happy to see the right one :)
|
||||
time.sleep(1)
|
||||
return proc
|
||||
|
||||
exit('Error starting RethinkDB, reason is: {}'.format(line))
|
||||
|
Loading…
x
Reference in New Issue
Block a user