charveasna / couchdb-python

Automatically exported from code.google.com/p/couchdb-python
Other
0 stars 0 forks source link

Document class is not like examples #192

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
0. db = s['database']
1. class Person(Document):
    ...
2. person = Person(...)
3. person.store(db)

What is the expected output? What do you see instead?
AttributeError: 'Person' object has no attribute 'store'

What version of the product are you using? On what operating system?
couchdb 1.1.2 on Mac OS X Leopard

Please provide any additional information below.
I've checked client.py code and store method doesn't exists, i'd like to create 
a Patch, but i don't know how can i contribute.

Original issue reported on code.google.com by jul...@pikhub.com on 29 Jul 2011 at 11:59

GoogleCodeExporter commented 8 years ago
You have mixed up couchdb.client.Document and couchdb.mapping.Document classes. 
Example is about second one. Document from client.py module is just raw 
representation of CouchDB document, not suited base for scheme mapping.

Original comment by kxepal on 30 Jul 2011 at 6:44

GoogleCodeExporter commented 8 years ago
Appears to be invalid.

Original comment by djc.ochtman on 21 Sep 2012 at 8:11