Open GoogleCodeExporter opened 8 years ago
I understand idea of this patch, but it doesn't solves issue:
class Image(Mapping):
name = TextField()
url = TextField()
class Post(Mapping):
title = TextField()
logo = DictField(Image, default={'name': 'post logo'})
attached_image = DictField(Mapping.build(
name=TextField(),
url=TextField()
), default=Image(name='attached image'))
post = Post(title='test post') # TypeError: MappingMeta object argument after
** must be a mapping, not Image
I suppose that better to implement full dict API to Mapping instance because it
represented ORM to dict object instead of trying to do same thing within Field
instances.
Original comment by kxepal
on 8 Jun 2011 at 4:28
This issue has been migrated to GitHub. Please continue discussion here:
https://github.com/djc/couchdb-python/issues/185
Original comment by djc.ochtman
on 15 Jul 2014 at 7:21
Original issue reported on code.google.com by
daevaorn
on 6 Jun 2011 at 11:31Attachments: