Skip to content

Document wrapping is lost on sorting #4

@neithere

Description

@neithere

Let's find something in the database:

qs = Foo.find(db, query)

here qs is a monk.modeling.MongoResultSet instance; now sort the documents:

qs2 = qs.sort('foo')

...whoops, qs2 is a pymongo.cursor.Cursor, i.e. monk.modeling.Document wrapping is lost.

Currently MongoResultSet simply redirects __getattr__ to Cursor; it should wrap the results in some cases as it does in __iter__.

Note: This issue has been automatically migrated from Bitbucket
Created by @neithere on 2012-05-17 01:27:32+00:00, last updated: 2012-05-17 01:28:09+00:00

Metadata

Metadata

Assignees

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions