def METHOD_NAME(date_time):
    '''Converts a datetime object to unix timestamp'''
    try:
        return int(time.mktime(date_time.timetuple()))
    except OverflowError:
        return 2145916800  # Y2038 bug in time.mktime on 32bit float systems. Use 2038 Jan 1 UTC for db timestamp instead.