mirror of
https://github.com/Chia-Network/chia-blockchain.git
synced 2024-09-11 10:56:14 +03:00
loader
This commit is contained in:
parent
7168903ed2
commit
daea33beae
@ -374,7 +374,7 @@ class WalletRpcApi:
|
||||
"wallet_id": cc_wallet.wallet_info.id,
|
||||
}
|
||||
except Exception as e:
|
||||
log.error("FAILED {e}")
|
||||
log.error(f"FAILED {e}")
|
||||
return {"success": False, "reason": str(e)}
|
||||
elif request["mode"] == "existing":
|
||||
try:
|
||||
@ -384,7 +384,7 @@ class WalletRpcApi:
|
||||
asyncio.ensure_future(self.create_backup_and_upload(host))
|
||||
return {"success": True, "type": cc_wallet.wallet_info.type}
|
||||
except Exception as e:
|
||||
log.error("FAILED2 {e}")
|
||||
log.error(f"FAILED2 {e}")
|
||||
return {"success": False, "reason": str(e)}
|
||||
if request["wallet_type"] == "rl_wallet":
|
||||
if request["rl_type"] == "admin":
|
||||
@ -408,7 +408,7 @@ class WalletRpcApi:
|
||||
"pubkey": rl_admin.rl_info.admin_pubkey.hex(),
|
||||
}
|
||||
except Exception as e:
|
||||
log.error("FAILED {e}")
|
||||
log.error(f"FAILED {e}")
|
||||
return {"success": False, "reason": str(e)}
|
||||
elif request["rl_type"] == "user":
|
||||
log.info("Create rl user wallet")
|
||||
|
@ -13,8 +13,7 @@ from src.types.sized_bytes import bytes32
|
||||
from src.types.spend_bundle import CoinSolution, SpendBundle
|
||||
from src.util.condition_tools import conditions_dict_for_solution
|
||||
from src.util.ints import uint64
|
||||
from src.wallet.puzzles.load_clvm import load_clvm
|
||||
|
||||
from src.wallet.puzzles.cc_loader import CC_MOD
|
||||
from src.wallet.puzzles.genesis_by_coin_id_with_0 import (
|
||||
lineage_proof_for_genesis,
|
||||
lineage_proof_for_coin,
|
||||
@ -27,8 +26,6 @@ NULL_SIGNATURE = G2Element.generator() * 0
|
||||
|
||||
LOCK_INNER_PUZZLE = Program.from_bytes(bytes.fromhex("ff01ff8080")) # (q ())
|
||||
|
||||
CC_MOD = load_clvm("../puzzles/cc.clvm", package_or_requirement=__name__)
|
||||
|
||||
ANYONE_CAN_SPEND_PUZZLE = Program.to(1) # simply return the conditions
|
||||
|
||||
# information needed to spend a cc
|
||||
|
3
src/wallet/puzzles/cc_loader.py
Normal file
3
src/wallet/puzzles/cc_loader.py
Normal file
@ -0,0 +1,3 @@
|
||||
from src.wallet.puzzles.load_clvm import load_clvm
|
||||
|
||||
CC_MOD = load_clvm("cc.clvm", package_or_requirement=__name__)
|
Loading…
Reference in New Issue
Block a user