def calc_DST_utc_secs(start_tuple, timezone=UNIVERSAL, is_dst=False, weekday=SUN):
    """ Calculate DST transition in UTC seconds. DST can be specified as the 
    first weekday (usually Sunday) after a date and time in a local time zone. """
    start_tuple = fill_in_tuple(start_tuple)
    utc_secs = local_tuple_to_utc_secs(start_tuple, timezone, is_dst)
    utc_tuple = secs_to_tuple(utc_secs)
    
    # Walk to first day on or after start day that corresponds to weekday.
    # Compensate in case weekday changes in conversion to UTC.
    weekday = ((weekday + utc_tuple[6] - start_tuple[6]) % 7)
    while True:
        if utc_tuple[6] == weekday:
            break
        utc_secs += DAY_SECONDS
        utc_tuple = secs_to_tuple(utc_secs)
    return utc_secs
 Calculate DST transition in UTC seconds. DST can be specified as the 
    first weekday (usually Sunday) after a date and time in a local time zone. 
recipes/Python/576546_DateTimeSyncer_Daylight_Savings_Time/recipe-576546.py