-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BackendAlreadyExists: rclone storage base path already exists on emtpy dir #57
Comments
The tests for the backends encourage backends to throw the BackendAlreadyExists if the directory for the backend already exists. In this case the directory is the I'm not sure this is absolutely correct or sensible though - what do you think @ThomasWaldmann ? Should rclone only raise this error if the destination has something in it? For use with s3, people often create the buckets in advance and then don't give rclone enough permissions to create buckets. Possible workarounds for you @bjo81
|
@ThomasWaldmann also thought it's related to the existing bucket, but as already quoted:
and the bucket is empty, so it should be possible to create the "mail" directory in it. |
Guess the point of the other backends raising if the base dir exists is because for them (fs, sftp), an existing directory means that "there is already something". A bit more precise would be to only raise if there is an existing non-empty directory I guess. |
@bjo81 yeah, we seem to have 2 issues here:
|
I am working on fixing the tests, guess it will become something like this:
|
I think that works better, and it fixes the problem with s3 directories not existing unless they have files in. |
@ThomasWaldmann give me a ping when you've updated the test and I'll send a PR for the rclone backend to fix. |
we shouldn't check just for the base directory and reject if it exists, that is troublesome for cloud storages. also, it is not really a problem if we just use an empty filesystem or sftp directory - we should only reject if there is stuff inside.
backend.create: only reject non-empty storage, see #57
Fixed by #62. |
As discussed with @ThomasWaldmann on IRC who told me to ping @ncw:
But it's empty:
The bucket was freshly created and it's nothing in there.
The text was updated successfully, but these errors were encountered: