

def _from_base_type(self, value):
    if isinstance(value, str):
        try:
            return unicode(value, 'utf-8')
        except UnicodeDecodeError:
            pass

dataset/ETHPy150Open GoogleCloudPlatform/datastore-ndb-python/ndb/model.py TextProperty._from_base_type/original