def line_to_tuple(stringa: str) -> tuple:
    """
    Converts str to (str, int).
    :param stringa: Must have len(stringa) > 1. Accepts
                    1 fireflux squad
                    1  fireflux squad
                    1x fireflux squad
                    1 fireflux squad (mtga) 333
                    fireflux squad 1
    :return: (str, int)
    """
    stringa = stringa.strip().replace("  ", " ")
    if stringa[0].isdigit():  # if format: 1 tarmogoyf
        copies, name = stringa.split(" ", 1)
    elif stringa[0].isalpha():  # if format: tarmogoyf 1
        name, copies = stringa.rsplit(" ", 1)
    else:
        raise ValueError

    copies = int(copies.replace("x", ""))
    if name[:2] == "x ":
        name = name[2:]

    name = name.split(" (")[0]  # for MTGA export
    return name, copies