tallow config to be None in constructor of Interface - electrum - Electrum Bitcoin wallet HTML git clone https://git.parazyd.org/electrum DIR Log DIR Files DIR Refs DIR Submodules --- DIR commit 81b29a48a1912175629a2962e2240dc1d220fedf DIR parent 1a781036cf0a3d04c5e170ef71fbf3e36c2ab908 HTML Author: thomasv <thomasv@gitorious> Date: Fri, 12 Oct 2012 16:31:05 +0200 allow config to be None in constructor of Interface Diffstat: M lib/interface.py | 6 +++++- M scripts/blocks | 3 +-- 2 files changed, 6 insertions(+), 3 deletions(-) --- DIR diff --git a/lib/interface.py b/lib/interface.py t@@ -285,8 +285,12 @@ class TcpStratumInterface(InterfaceAncestor): class Interface(TcpStratumInterface, HttpStratumInterface): - def __init__(self, config): + def __init__(self, config = None): + if config is None: + from simple_config import SimpleConfig + config = SimpleConfig() + try: s = config.get('server') host, port, protocol = s.split(':') DIR diff --git a/scripts/blocks b/scripts/blocks t@@ -2,8 +2,7 @@ import electrum -i = electrum.Interface({'server':'electrum.novit.ro:50001:t'}) - +i = electrum.Interface() i.start() i.send([('blockchain.numblocks.subscribe',[])])