dwsmith1983 opened a new issue, #7677:
URL: https://github.com/apache/datafusion-comet/issues/7677

   ### Describe the bug
   
   `handle::tests::cancel_wakes_a_waiting_reader` in 
`native/local/src/handle.rs`, added in #6883, fails intermittently in the merge 
queue:
   
   ```
   thread 'handle::tests::cancel_wakes_a_waiting_reader' panicked at 
local/src/handle.rs:214:9:
   assertion `left == right` failed
     left: 1
    right: 0
   ```
   
   It evicted #7508 
([run](https://github.com/apache/datafusion-comet/actions/runs/44210718975)) on 
2026-11-18. #7508 doesn't touch `native/local`.
   
   `cancel()` drops the query's stream on the calling thread, which aborts the 
spawned partition tasks. Tokio drops each aborted task later on a runtime 
worker, and the partition stream that holds the plan reference goes with it. 
The test checks `refs.strong_count()` as soon as the reader sees the cancel, so 
the check can run before the worker has dropped the task. The crate's other 
teardown checks (`wait_released` in `tests/execution.rs`, the loops in 
`tests/bridge.rs`) wait for the count to reach zero under a deadline.
   
   ### Steps to reproduce
   
   Run `cargo test -p datafusion-comet-local --lib 
handle::tests::cancel_wakes_a_waiting_reader` repeatedly. It fails when the 
worker hasn't dropped the aborted task by the time the assert runs.
   
   ### Expected behavior
   
   The test should wait, with a deadline, for the strong count to reach zero, 
like the other teardown checks in the crate.
   


-- 
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