sadikovi commented on PR #44127:
URL: https://github.com/apache/spark/pull/44127#issuecomment-1849120692
Nah, I can reproduce this on Ubuntu. This is due to usage of symlinks. If
you have a symlink pointing to a directory, the createDirectories API will
throw an error. You can run this on Linux:
```shell
%sh
# mkdir /tmp/ivan/
# ln -s /tmp/ivan /tmp/ivan_symlink
ls -alh /tmp/ivan_symlink
```
```scala
import java.nio.file._
Files.createDirectories(Paths.get("/tmp/ivan_symlink"))
// Throws FileAlreadyExistsException: /tmp/ivan_symlink
```
java.io.File returns false correctly because the directory exists.
--
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]