def main():
    args = init_parser().parse_args(sys.argv[1:])
    client = Client(protocol=args.protocol,
                         endpoint=args.endpoint)

    try:
        while True:
            input_str = prompt(current_db=client.db_name)

            if input_str:
                command, args = parse_input(input_str)

                if not command == "DBCONNECT":
                    status, result = client.send_cmd(client.db_uid, command, args)
                    output_result(status, result)
                else:
                    client.connect(*args)
    except __HOLE__:
        sys.exit(0)
dataset/ETHPy150Open oleiade/Elevator/elevator_cli/main.py/main