jorisvandenbossche commented on PR #13577:
URL: https://github.com/apache/arrow/pull/13577#issuecomment-1181412377
Just wondering: to what extent is this a corner case that just happens to be
in our tests, or is there a practical value in allowing trailing slashes?
Because for example also the LocalFileSystem does not allow trailing slashes
in a similar example:
```
In [51]: from pyarrow.fs import LocalFileSystem
In [52]: local = LocalFileSystem()
In [53]: local.create_dir("py-test")
In [54]: with local.open_output_stream("py-test/test.txt/") as out_stream:
...: out_stream.write(b"Hello world!")
...
IsADirectoryError: [Errno 21] Failed to open local file 'py-test/test.txt/'
Detail: [errno 21] Is a directory
```
(which is an error that makes sense to me, also Python's `open` will
complain that it is a directory and not a file in the equivalent example)
--
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]