Repository navigation
Conversation
…rs (#2169) The cheatsheet recommended callable predicates (n({"age": lambda x: x > 30})) that validation rejects on every engine. The docs example audit never caught it: its RST regex only matched code blocks at column zero, so 50 of 56 quick.rst blocks (58 of 407 across GFQL docs) were never extracted, and bare matchers only build an AST. - quick.rst: declarative predicates (gt, lt, between) replace callables; let() examples select bindings with output=; remote() shown as a let() binding (a plain-chain remote step raises NotImplementedError); pandas-only .empty replaced; engine section notes what auto runs on pandas for Polars input; stale xfail removed; placeholder/remote blocks marked skip. - docs/test_doc_examples.py: indent-aware RST extractor (strict superset of the old blocks and markers); new test executes every runnable quick.rst example on a pandas-bound and a Polars-bound graph, requires identical rows, explicit expected rows for the predicate examples, and accepts a pandas result under auto only when engine='polars' refuses the matcher. - Product test pins structured E201 rejection of callables (#967 stays open). Co-Authored-By: Claude Opus 5.5 <[email protected]>
Its polars params need polars, which only test-polars installs; the lane completeness gate requires the file in POLARS_TEST_FILES. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This branch has not been deployed
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #2169. Keeps #967 (restoring local callables) open.
Problem
The GFQL cheatsheet recommended
n({"age": lambda x: x > 30}), which validation rejects on pandas and Polars withGFQLTypeErrorE201. The docs example audit missed it for two reasons:.. code-block::at column zero, so blocks nested under bullets were never extracted: 50 of 56 inquick.rst, 58 of 407 across GFQL docs;n({...})only construct an AST and never execute.Changes
gt,lt,between) replace callables;let()examples select bindings withoutput=(results never had per-binding columns);remote()shown as alet()binding, since a plain-chain remote step raisesNotImplementedError; pandas-only.emptyreplaced withlen(...); the engine section states thatengine='auto'runs Polars-unsupported features (query=strings, same-pathwhere=) on pandas and returns pandas frames, whileengine='polars'raises; stale xfail removed; placeholder and server-dependent blocks markeddoc-test: skip.quick.rstexample on a pandas-bound and a Polars-bound graph and requires identical rows, with explicit expected rows for the predicate examples. A pandas result underautois accepted only when explicitengine='polars'refuses the same matcher.No runtime or serialization change.
Validation (dgx-spark, image
test-rapids-official:26.02-gfql-polars, polars 1.35.2)pytest docs/test_doc_examples.py: 24 passed, 13 skipped. 31 quick.rst examples execute on both engines with matching rows.test_callable_filter_rejection.py: 6 passed.let()examples reachMust call login() first, notNotImplementedError.Limits: the first Cypher example (
:Person/:FOLLOWS) runs with row parity but returns no rows on the shared fixture. GPU, remote andcompute_cugraphexamples stay auto-skipped. The same wronglet()access pattern also appears in skip-marked blocks in overview.rst, about.rst and the spec docs; that is tracked separately.🤖 Generated with Claude Code