def get_range(periods):
    """Find from-date,to-date for simulation from list of file periods

    Args:
        periods (list of tuples): ranges of file dates as string

    Returns:
        from_date, to_date (string): or None, None

    """ 
    try:
        lower, higher = int(periods[0][0]), int(periods[0][1])
        for nr in periods[1:]:
            low, high = int(nr[0]), int(nr[1])
            lower = min(low,lower)
            higher = max(high, higher)
        # to keep into account the open interval
        higher = higher
    except:
        return None, None
    return str(lower), str(higher)