try to import all python dependencies from the main script
This commit is contained in:
@@ -26,15 +26,8 @@ import hmac
|
||||
import version
|
||||
from util import print_error, InvalidPassword
|
||||
|
||||
try:
|
||||
import ecdsa
|
||||
except ImportError:
|
||||
sys.exit("Error: python-ecdsa does not seem to be installed. Try 'sudo pip install ecdsa'")
|
||||
|
||||
try:
|
||||
import aes
|
||||
except ImportError:
|
||||
sys.exit("Error: AES does not seem to be installed. Try 'sudo pip install slowaes'")
|
||||
import ecdsa
|
||||
import aes
|
||||
|
||||
################################## transactions
|
||||
|
||||
@@ -401,12 +394,7 @@ def is_private_key(key):
|
||||
|
||||
########### end pywallet functions #######################
|
||||
|
||||
try:
|
||||
from ecdsa.ecdsa import curve_secp256k1, generator_secp256k1
|
||||
except Exception:
|
||||
print "cannot import ecdsa.curve_secp256k1. You probably need to upgrade ecdsa.\nTry: sudo pip install --upgrade ecdsa"
|
||||
exit()
|
||||
|
||||
from ecdsa.ecdsa import curve_secp256k1, generator_secp256k1
|
||||
from ecdsa.curves import SECP256k1
|
||||
from ecdsa.ellipticcurve import Point
|
||||
from ecdsa.util import string_to_number, number_to_string
|
||||
|
||||
Reference in New Issue
Block a user