From c0378a5ba0dd3ba86a013a12b3eec0e267a85ee6 Mon Sep 17 00:00:00 2001 From: ThomasV Date: Sat, 15 Mar 2014 11:04:11 +0100 Subject: [PATCH] fix getservers: wait until they are available --- lib/commands.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/commands.py b/lib/commands.py index 4dadf344..d09b376f 100644 --- a/lib/commands.py +++ b/lib/commands.py @@ -16,6 +16,7 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . +import time from util import * from bitcoin import * from decimal import Decimal @@ -237,6 +238,8 @@ class Commands: return out def getservers(self): + while not self.network.is_up_to_date(): + time.sleep(0.1) return self.network.get_servers() def getversion(self):