Created
March 18, 2011 05:38
-
-
Save andresdouglas/875662 to your computer and use it in GitHub Desktop.
mongokit is returning dictionaries instead of Document instances
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(Pdb) p base_object_list | |
<mongokit.cursor.Cursor object at 0x101fc0dd0> | |
(Pdb) p base_object_list[0] | |
{u'rating': 7, u'_id': ObjectId('4d82eed3051df234ba000000'), u'name': u'andres'} | |
(Pdb) p type(base_object_list[0]) | |
<type 'dict'> | |
(Pdb) p self | |
<bakodo.user_app.api.resources.MongokitTestResource object at 0x102314cd0> | |
(Pdb) p self._meta.object_class | |
<class 'user_app.mongokit_models.MongokitTestModel'> | |
(Pdb) p self._meta.object_class.use_dot_notation | |
True |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment