flask-mongoengine
flask-mongoengine copied to clipboard
Pagination breaks previous limits
When you create a pagination, it doesn't take into account any .limit() or .skip() that has already been done to the QuerySet being inputted. For example, if I do articles.objects().limit(3), paginating t for 10 items per page would remove the limit of max 3 articles.
I would consider this a bug as it makes it impossible to modify the query size in several steps.
@ripperdoc it is strange to ask to check this with master, after 5 years issue. But who knows :) I just merged https://github.com/MongoEngine/flask-mongoengine/pull/422 it is on connected topic, and maybe fix your issue too. I do not have a chance to make a dedicated test for it, yet. As I am very limited in time, and want to bring a little life to this repo.