From 08b21121143caa8b460254419d4dae257a10ef8f Mon Sep 17 00:00:00 2001 From: 0ceanSlim Date: Fri, 10 Nov 2023 15:29:41 -0500 Subject: [PATCH] fic issueAsset WIP --- src/issueAsset.py | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/issueAsset.py b/src/issueAsset.py index b4c0440..7111f8a 100644 --- a/src/issueAsset.py +++ b/src/issueAsset.py @@ -2,10 +2,17 @@ from bitcoinrpc.authproxy import AuthServiceProxy, JSONRPCException import json import hashlib from getpass import getpass -from util.rpcHandler import read_rpc_config, create_rpc_connection -# Read the RPC configuration from the configuration file -rpc_host, rpc_port, rpc_user, rpc_password = read_rpc_config() +def get_rpc_credentials_from_file(filename='rpc_config.json'): + with open(filename, 'r') as config_file: + config = json.load(config_file) + + rpc_host = config['rpc_host'] + rpc_port = config['rpc_port'] + rpc_user = config['rpc_user'] + rpc_password = config['rpc_password'] + + return rpc_host, rpc_port, rpc_user, rpc_password def generate_contract(): name = input("Enter the asset name: ")