def METHOD_NAME(tx_file: pl.Path):
    # we want to submit the Tx and then re-submit it and see the expected error, to make
    # sure the Tx made it to mempool
    for r in range(5):
        try:
            cluster.g_transaction.submit_tx_bare(tx_file=tx_file)
        except clusterlib.CLIError as exc:
            err_str = str(exc)
            if r == 0 and "(BadInputsUTxO" in err_str:
                raise Exception(  # pylint: disable=broad-exception-raised
                    "Tx input is missing, maybe temporary fork?"
                ) from exc
            if "(BadInputsUTxO" not in err_str:
                raise
            break
    else:
        raise AssertionError("Failed to make sure the Tx is in mempool")