From ecc296cf6751cea95ef077e254a92ce8c7f8510e Mon Sep 17 00:00:00 2001 From: SomberNight Date: Tue, 11 Sep 2018 20:39:16 +0200 Subject: [PATCH] fix race in session.subscribe --- electrum/interface.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/electrum/interface.py b/electrum/interface.py index 1d165f6f0..d1e83c397 100644 --- a/electrum/interface.py +++ b/electrum/interface.py @@ -75,8 +75,8 @@ class NotificationSession(ClientSession): self.subscriptions[key].append(queue) result = self.cache[key] else: - result = await self.send_request(method, params) self.subscriptions[key] = [queue] + result = await self.send_request(method, params) self.cache[key] = result await queue.put(params + [result])