fixes and cleanups throughout

This commit is contained in:
The MMGen Project 2022-02-03 20:40:42 +00:00
commit d6872ddb87
Signed by: mmgen
GPG key ID: 3F8B1861E32B7DA2
30 changed files with 143 additions and 143 deletions

View file

@ -92,9 +92,8 @@ exec_wrapper_tracemalloc_setup()
try:
sys.argv.pop(0)
exec_wrapper_execed_file = sys.argv[0]
with open(sys.argv[0]) as fp:
text = fp.read()
exec(text)
with open(exec_wrapper_execed_file) as fp:
exec(fp.read())
except SystemExit as e:
if e.code != 0 and not os.getenv('EXEC_WRAPPER_NO_TRACEBACK'):
exec_wrapper_write_traceback()

View file

@ -26,7 +26,8 @@ cmd_args = opts.init(opts_data)
from mmgen.tx import *
if len(cmd_args) != 1: opts.usage()
if len(cmd_args) != 1:
opts.usage()
tx = MMGenTX(cmd_args[0],quiet_open=True)
tx.write_to_file(ask_tty=False,ask_overwrite=not opt.quiet,ask_write=not opt.quiet)