buraksenn opened a new pull request, #23306:
URL: https://github.com/apache/datafusion/pull/23306

   ## Which issue does this PR close?
   - Closes #22227..
   
   ## Rationale for this change
   Please check #22227 
   
   ## What changes are included in this PR?
   Instead of panicking we return execution error buy checking sizes in 
array_resize.
   
   Outcome is:
   ```
   ➜  datafusion git:(fix-array-resize-overflow-panic)  cargo run -p 
datafusion-cli -- -c "SELECT array_resize(make_array(1), 9223372036854775807, 
0)"
       Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.54s
        Running `target/debug/datafusion-cli -c 'SELECT 
array_resize(make_array(1), 9223372036854775807, 0)'`
   DataFusion CLI v54.0.0
   Error: Execution error: array_resize: resulting array of 9223372036854775807 
elements exceeds the maximum array size
   ```
   
   in issue it was:
   <img width="871" height="281" alt="image" 
src="https://github.com/user-attachments/assets/6ebdda2c-5e74-4ca7-bc7d-51393a95fa24";
 />
   
   
   
   
   ## Are these changes tested?
   yes. added new unit and slt tests
   
   ## Are there any user-facing changes?
   instead of panic users will see execution error


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