On version 0.0.21, filtering might fail if queries specify both order_by combined with limit and offset.
Traceback
(order_by=order, limit=limit, offset=offset)
File "/usr/local/lib/python3.8/site-packages/pydbantic/core.py", line 1143, in all
return await cls.select('*', **parameters, backward_refs=backward_refs)
File "/usr/local/lib/python3.8/site-packages/pydbantic/core.py", line 966, in select
sel = sel.order_by(order_by)
File "<string>", line 2, in order_by
File "/usr/local/lib/python3.8/site-packages/sqlalchemy/sql/base.py", line 110, in _generative
x = fn(self, *args, **kw)
File "<string>", line 2, in order_by
File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/base.py", line 229, in generate
assertion(self, fn.__name__)
File "/usr/local/lib/python3.8/site-packages/sqlalchemy/orm/query.py", line 312, in _no_limit_offset
raise sa_exc.InvalidRequestError(
sqlalchemy.exc.InvalidRequestError: Query.order_by() being called on a Query which already has LIMIT or OFFSET applied. Call order_by() before limit() or offset() are applied.
Description
On version 0.0.21, filtering might fail if queries specify both
order_by
combined with limit andoffset
.Traceback