def METHOD_NAME(logger: logging.Logger) -> None:
    """
    This method cleans up the temporary tables used by the forwards methodsa and
    returns us to the original state if the forwards method has failed somewhere
    in the middle. Otherwise it's a no-op.
    """
    cluster = get_cluster(StorageSetKey.TRANSACTIONS)
    if not cluster.is_single_node():
        return
    clickhouse = cluster.get_query_connection(ClickhouseClientSettings.MIGRATE)
    def table_exists(table_name: str) -> bool:
        return clickhouse.execute(f"EXISTS TABLE {table_name};").results == [(1,)]
    if not table_exists(TABLE_NAME):
        raise Exception(f"Table {TABLE_NAME} is missing")
    if table_exists(TABLE_NAME_NEW):
        logger.info(f"Dropping table {TABLE_NAME_NEW}")
        time.sleep(1)
        clickhouse.execute(f"DROP TABLE {TABLE_NAME_NEW};")
    if table_exists(TABLE_NAME_OLD):
        logger.info(f"Dropping table {TABLE_NAME_OLD}")
        time.sleep(1)
        clickhouse.execute(f"DROP TABLE {TABLE_NAME_OLD};")