davlee1972 commented on issue #41357:
URL: https://github.com/apache/arrow/issues/41357#issuecomment-2079716502

   I think this needs be solved in C++.. Right now the code is calling 
listdir() followed by statfile()..
   
   It needs the option to call python's equivalent to scandir().
   
   
https://github.com/apache/arrow/blob/0f56339ee803858b597418aefdabb993def19f48/cpp/src/arrow/filesystem/localfs.cc#L117C1-L123C1
   ```
   
       if (err == ERROR_FILE_NOT_FOUND || err == ERROR_PATH_NOT_FOUND) {
         info.set_path(bytes_path);
         info.set_type(FileType::NotFound);
         info.set_mtime(kNoTime);
         info.set_size(kNoSize);
         return info;
       } else {
         return IOErrorFromWinError(GetLastError(), "Failed querying 
information for path '",
                                    bytes_path, "'");
       }
   ```
   


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

Reply via email to