helper function to serialize some objects for prettier return

def _serializer(obj):
    '''
    helper function to serialize some objects for prettier return
    '''
    import datetime
    if isinstance(obj, datetime.datetime):
        if obj.utcoffset() is not None:
            obj = obj - obj.utcoffset()
        return obj.__str__()
    return obj