diff --git a/green_cli/common.py b/green_cli/common.py index b78cc82..f680fee 100644 --- a/green_cli/common.py +++ b/green_cli/common.py @@ -425,49 +425,6 @@ def gettransactions(session, summary, details): result = _txlist_summary(result) if summary else format_output(result) click.echo(result) -@green.command() -@click.option('--addressee', '-a', type=(Address(), Amount()), expose_value=False, multiple=True) -@click.option('--subaccount', default=0, expose_value=False, callback=details_json) -@click.option('--fee-rate', '-f', type=int, expose_value=False, callback=details_json) -@with_login -@print_result -def createtransaction(session, details): - """Create an outgoing transaction.""" - add_utxos_to_transaction(session, details) - return gdk_resolve(gdk.create_transaction(session.session_obj, json.dumps(details))) - -@green.command() -@click.argument('details', type=click.File('rb')) -@with_login -@print_result -@with_gdk_resolve -def signtransaction(session, details): - """Sign a transaction. - - Pass in the transaction details json from createtransaction. TXDETAILS can be a filename or - to - read from standard input, e.g. - - $ green createtransaction -a
1000 | green signtransaction - - """ - details = details.read().decode('utf-8') - return gdk.sign_transaction(session.session_obj, details) - -@green.command() -@click.argument('details', type=click.File('rb')) -@with_login -@print_result -@with_gdk_resolve -def sendtransaction(session, details): - """Send a transaction. - - Send a transaction previously returned by signtransaction. TXDETAILS can be a filename or - to - read from standard input, e.g. - - $ green createtransaction -a
1000 | green signtransaction - | green sendtransaction - - """ - details = details.read().decode('utf-8') - return gdk.send_transaction(session.session_obj, details) - def _send_transaction(session, details): add_utxos_to_transaction(session, details) details = gdk_resolve(gdk.create_transaction(session.session_obj, json.dumps(details))) diff --git a/green_cli/liquid.py b/green_cli/liquid.py index cbeba08..91971f7 100644 --- a/green_cli/liquid.py +++ b/green_cli/liquid.py @@ -103,11 +103,6 @@ def sendtoaddress(session, details): raise click.ClickException("Unsafe asset amount conversion disabled") return green_cli.common._send_transaction(session, details) -# Insert asset into addressee option for createtransaction -params = {p.name: p for p in green_cli.common.createtransaction.params} -params['addressee'].type = click.Tuple((Address(), Asset(), Amount())) -params['addressee'].nargs = 3 - # Add '--confidential' option to getbalance and getunspentoutputs confidential_option = click.Option( ['--confidential',], is_flag=True, expose_value=False, callback=details_json,