python - Get a list of dynamic properties with an NDB Expando Model? -


with db appears myexpando.dynamic_properties(), trying in ndb attributeerror dynamic_properties.

can't find in docs change this.

when using ndb should using _properties list of properties

    db, ndb, users, urlfetch, , memcache modules imported. dev~cash-drawer> class x(ndb.expando): ...    pass ...  dev~cash-drawer>  dev~cash-drawer>  dev~cash-drawer> y = x() dev~cash-drawer> y.a = ndb.genericproperty() dev~cash-drawer> y.a = 100 dev~cash-drawer> y.a 100 dev~cash-drawer> repr(y.a) '100' dev~cash-drawer> type(y.a) <type 'int'> dev~cash-drawer> y._properties {'a': genericproperty('a')} dev~cash-drawer>  

see docs https://developers.google.com/appengine/docs/python/ndb/entities#expando


Comments

Popular posts from this blog

android - getbluetoothservice() called with no bluetoothmanagercallback -

sql - ASP.NET SqlDataSource, like on SelectCommand -

ios - Undefined symbols for architecture armv7: "_OBJC_CLASS_$_SSZipArchive" -