klin333 opened a new issue, #2819:
URL: https://github.com/apache/arrow-adbc/issues/2819

   ### What happened?
   
   Calling `adbc_connection_get_objects` seems to crash R (ie total crash of R 
session), as soon as R's garbage collection is run. Maybe segfault somewhere 
from freeing of resources when gc() is triggered. Pretty sure gc() triggers the 
crash because the crash will happen randomly a few seconds after calling 
`convert_array_stream` ie not immediately after the call but randomly after it 
- calling gc() manually will immediately trigger the R crash.
   
   
   ```{r}
   
   uri <- "SECRET"
   db <- adbcdrivermanager::adbc_database_init(adbcsnowflake::adbcsnowflake(), 
uri = uri)
   drivermanager_con <- adbcdrivermanager::adbc_connection_init(db)
   
   nfo <- adbcdrivermanager::adbc_connection_get_objects(drivermanager_con, 
depth = 3L, table_name = 'FLIGHTS') # can leave out depth and table_name and 
still will crash
   res <- nanoarrow::convert_array_stream(nfo) # can also substitute this line 
for simple console print of nfo, and still will crash
   # sessionInfo()
   gc() # trigger for crash (or just wait a bit for gc to run itself and will 
also crash)
   ```
   
   
   sessionInfo()
   ```
   R version 4.3.2 (2023-10-31 ucrt)
   Platform: x86_64-w64-mingw32/x64 (64-bit)
   Running under: Windows 11 x64 (build 22631)
   
   Matrix products: default
   
   
   locale:
   [1] LC_COLLATE=English_Australia.utf8  LC_CTYPE=English_Australia.utf8    
LC_MONETARY=English_Australia.utf8 LC_NUMERIC=C                      
   [5] LC_TIME=English_Australia.utf8    
   
   time zone: Australia/Sydney
   tzcode source: internal
   
   attached base packages:
   [1] graphics  grDevices utils     methods   base     
   
   loaded via a namespace (and not attached):
    [1] compiler_4.3.2           cli_3.6.5                tools_4.3.2           
   rstudioapi_0.16.0        adbcsnowflake_0.17.0     stats_4.3.2             
    [7] nanoarrow_0.6.0-1        vctrs_0.6.5              
adbcdrivermanager_0.17.0 rlang_1.1.6              renv_1.1.4     
   ```
   
   ### Stack Trace
   
   _No response_
   
   ### How can we reproduce the bug?
   
   _No response_
   
   ### Environment/Setup
   
   _No response_


-- 
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: issues-unsubscr...@arrow.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to