You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While adding types to the query pagination code, I realized that a good chunk of the code appears to implicitly assume that queries do not contain type coercions: for example, there was a lot of use of ast.name.value, which is only defined for FieldNode and doesn't work for InlineFragmentNode AST types.
This situation emerged because our SQL backend doesn't currently support type coercions (because SQL in general doesn't do table inheritance), and because we prototyped the query pagination code on SQL.
I am doing my best to fix the code as best I can, but I'm not sure I can get everything. We need more test coverage to prove that query pagination works for all queries, including ones with type coercions.
The text was updated successfully, but these errors were encountered:
Worth checking why test_query_pagination.py:test_with_compiler_tests doesn't catch those bugs. It runs pagination against all defined compiler test inputs, checking that no errors are raised.
Ah, the current tests pass because we always paginate at the root right now. We have tests for the parameterizer that make it insert filters on a different path, but we don't have one with type coercions.
While adding types to the query pagination code, I realized that a good chunk of the code appears to implicitly assume that queries do not contain type coercions: for example, there was a lot of use of
ast.name.value
, which is only defined forFieldNode
and doesn't work forInlineFragmentNode
AST types.This situation emerged because our SQL backend doesn't currently support type coercions (because SQL in general doesn't do table inheritance), and because we prototyped the query pagination code on SQL.
I am doing my best to fix the code as best I can, but I'm not sure I can get everything. We need more test coverage to prove that query pagination works for all queries, including ones with type coercions.
The text was updated successfully, but these errors were encountered: