- I get the client timestamp as
Wed, 20 Nov 2013 13:53:35 GMT
- I want to convert this into a python utc timestamp so that I can subtract it and get remaining number of days in month
def get_days_left_in_month(from_date): # todo : how to validate if from_date is valid? start_day, end_day = Day.get_start_end_days_for_year_and_month( from_date.year, from_date.month ) remaining_days = (end_day - from_date).days return remaining_days if remaining_days == 0 else remaining_days - 1
How can I do this using python?