def last_minute_of_a_month(year, month):
    first_day = datetime.datetime(year, month, 1)
    number_of_days = calendar.monthrange(year, month)[1]
    first_day_next_month = first_day + datetime.timedelta(days=number_of_days)
    last_day_last_minute = first_day_next_month - datetime.timedelta(microseconds=1)
    return last_day_last_minute
dataset/ETHPy150Open Impactstory/total-impact-webapp/core_extras/batch_providers/load_batch_pmc.py/last_minute_of_a_month/original