-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path__init__.py
40 lines (30 loc) · 1.16 KB
/
__init__.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
import sys
import os
# these are ~duplicated from run_electrum:
is_bundle = getattr(sys, 'frozen', False)
is_local = not is_bundle and os.path.exists(os.path.join(os.path.dirname(os.path.dirname(__file__)), "electrum.desktop"))
# when running from source, on Windows, also search for DLLs in inner 'electrum' folder
if is_local and os.name == 'nt':
if hasattr(os, 'add_dll_directory'): # requires python 3.8+
os.add_dll_directory(os.path.dirname(__file__))
class GuiImportError(ImportError):
pass
from .version import ELECTRUM_VERSION
from .util import format_satoshis
from .wallet import Wallet
from .storage import WalletStorage
from .coinchooser import COIN_CHOOSERS
from .network import Network, pick_random_server
from .interface import Interface
from .simple_config import SimpleConfig
from . import bitcoin
from . import transaction
from . import daemon
from .transaction import Transaction
from .plugin import BasePlugin
from .commands import Commands, known_commands
from .logging import get_logger
__version__ = ELECTRUM_VERSION
_logger = get_logger(__name__)
if not __debug__:
_logger.warning(f"__debug__ is False. running with asserts disabled!")