def main():
args = parse_args()<EOL>try:<EOL><INDENT>hsm = pyhsm.base.YHSM(device=args.device, debug=args.debug)<EOL>if args.debug or args.verbose:<EOL><INDENT>print("<STR_LIT>" % (args.device))<EOL>print("<STR_LIT>" % (hsm.info()))<EOL>print("<STR_LIT>")<EOL><DEDENT>password = get_password(hsm, args)<EOL>otp = get_otp(hsm, args)<EOL>if not password and not otp:<EOL><INDENT>print("<STR_LIT>")<EOL>return <NUM_LIT:1><EOL><DEDENT>else:<EOL><INDENT>if args.debug or args.verbose:<EOL><INDENT>print("<STR_LIT>")<EOL><DEDENT>if hsm.unlock(password = password, otp = otp):<EOL><INDENT>if args.debug or args.verbose:<EOL><INDENT>print("<STR_LIT>")<EOL><DEDENT><DEDENT><DEDENT><DEDENT>except pyhsm.exception.YHSM_Error as e:<EOL><INDENT>sys.stderr.write("<STR_LIT>" % (e.reason))<EOL>if e.reason == "<STR_LIT>":<EOL><INDENT>sys.stderr.write("<STR_LIT>" + args.device + "<STR_LIT>")<EOL><DEDENT>return <NUM_LIT:1><EOL><DEDENT>return <NUM_LIT:0><EOL>
What will be executed when running as a stand alone program.