cloudpathlib
cloudpathlib copied to clipboard
Copy to non-existing S3 folder path creates a file with "/" instead of file name in that folder
Steps to reproduce:
# take an existing file
src = S3Path("s3://my-bucket/file.txt")
# and copy it into non-existent folder
dst = S3Path("s3://my-bucket/destination/")
src.copy(dst)
Current behavior
Creates a file with name /
inside the folder s3://my-bucket/destination/
Expected behavior
The file s3://my-bucket/destination/file.txt
is created