andygrove commented on PR #1826:
URL: 
https://github.com/apache/datafusion-python/pull/1826#issuecomment-6876042699

   @nuno-faria you were right that the `_test_three_library_query_planner` 
failure comes from upstream. I filed 
https://github.com/apache/datafusion/issues/27427 and opened a fix in 
https://github.com/apache/datafusion/pull/27428.
   
   `FFI_ExecutionPlan` never carried a plan's input requirements: input 
distribution, required ordering, `maintains_input_order`. When the host's 
optimizer rules run across FFI on the planner library's plan, 
`EnsureRequirements` can't see that `FinalPartitioned` needs hash-partitioned 
input, so it adds only a round-robin repartition. On 55, `SanityCheckPlan` also 
ran as a host-side rule and was just as blind, so the test passed. 
apache/datafusion#26461 moved the check into `DefaultPhysicalPlanner`, so 56 
rejects the plan.
   
   I cherry-picked the fix onto the `branch-56` commit this PR pins 
(`0f3b5a08`) and built this branch against it. The query-planner example suite 
passes (51/51, including `test_spawning_plan_across_three_libraries`), and so 
does the FFI example suite (59/59). Once the fix lands on `branch-56` and the 
pin here is bumped, this test should pass without changes on our side.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to