arachnid / aetycoon Goto Github PK
View Code? Open in Web Editor NEWaetycoon provides a library of useful App Engine datastore property classes.
aetycoon provides a library of useful App Engine datastore property classes.
aetycoon provides a library of useful App Engine datastore property classes. The property classes included here cover use cases that are too specialized to be included in the SDK, or simply weren't included, but are nevertheless generally useful. They include: - DerivedProperty, which allows you to automatically generate values - LowerCaseProperty, which stores the lower-cased value of another property - LengthProperty, which stores the length of another property - ChoiceProperty efficiently handles properties which may only be assigned a value from a limited set of choices - CompressedBlobProperty and CompressedTextProperty store data/text in a compressed form - ArrayProperty store array.array objects for lean and efficient POD type storage With aetycoon, you'll have all the properties you're ever likely to need.
If people set a validator in aetycoon property constructors, it is never used because validate() is never called. Properties should call validate() in get_value_for_datastore() to honor custom validators.
Hey,
Maybe I'm missing something, but aetycoon doesn't include a license file or notice. Could you please add one?
I am having some trouble using the transform property type.
In the case that the property being transformed is None or '', then this line throws an error:
if last_val == current_val:
return getattr(model_instance, self.__transformed_attr_name()) <- throws 'AttributeError: 'Foo object has no attribute '_derivedField' '
Here's the post:
http://googleappengine.blogspot.com/2009/07/writing-custom-property-classes.html
Just so that there's not much duplication everywhere.
from the docstring,
class DatastoreFile(db.Model):
... @DerivedProperty(name='sha1')
... def hash(self):
... return hashlib.sha1(self.data).hexdigest()
I would expect the property to be named 'sha1', not 'hash'. But actually it is 'hash',
file.hash
'943a702d06f34599aee1f8da8ef9f7296031d699'
file.sha1 will raise an AttributeError.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.