def validate(self, value):
    """Validate that assigned value is BlobInfo.

    Automatically converts from strings and BlobKey instances.
    """
    if isinstance(value, (basestring)):
      value = BlobInfo(BlobKey(value))
    elif isinstance(value, BlobKey):
      value = BlobInfo(value)
    return super(BlobReferenceProperty, self).validate(value)
Validate that assigned value is BlobInfo.

    Automatically converts from strings and BlobKey instances.
    
mapreduce/lib/blobstore/blobstore.py