Skip to content
This repository was archived by the owner on Nov 23, 2026. It is now read-only.
This repository was archived by the owner on Nov 23, 2026. It is now read-only.

Moving or copying the folder with a replace option does not work #10515

Closed

Description

@v-scharf

ocis: 5.1.0-prealpha+44bdea9608
web: 8.0.0-rc.5

Steps:

  • create folder1/file1.txt and subfolder/folder1/file2.txt
  • copy or move folder1 to subfolder/folder1 with replays option

Expect: subfolder/folder1 contains two files: file1.txt and file2.txt
Actual:
image

Screen.Recording.2024-02-26.at.15.44.54.mov

Same case uploading folder with replace works fine

Activity

  1. added
    Type:Bug
    on Feb 26, 2024
  2. moved this from Qualification to Prio 2 in Infinite Scale Team Boardon Feb 26, 2024
  3. added
    Priority:p2-high
    on Feb 27, 2024
  4. self-assigned this
    on Mar 13, 2024
  5. moved this from Prio 2 to In progress in Infinite Scale Team Boardon Mar 13, 2024
  6. kulmann commented on Mar 14, 2024

    @kulmann
    Contributor

    I don't agree with the expected behaviour. The content after replacing should be file1.txt. I'd only expect to have both text files if there was a Merge option, but there is none.

  7. v-scharf commented on Mar 14, 2024

    @v-scharf
    ContributorAuthor

    I don't agree with the expected behaviour. The content after replacing should be file1.txt. I'd only expect to have both text files if there was a Merge option, but there is none.

    then we have uploading folder issue. should be same behavior IMHO

    steps:

    • create f1/test.txt
    • upload f1 which contains file new.txt with replace option

    Result: f1 contains new.txt and test.txt

  8. JammingBen commented on Mar 20, 2024

    @JammingBen
    Contributor

    Not sure if we can do much about that the moment since uploading and copying/moving are being handled differently.

    Uploading a folder goes through each file separately to upload it. That means existing files in a folder are not affected. Whereas copying/moving are WebDAV operations and handle the folder itself as one resource. In case of replacing, the client sends an overwrite header to the server so it will replace the folder with all its contents completely.

    Solutions I can think of:

    • Improve on our wording: "Replace" becomes "Merge" in case of an upload.
    • Delete the existing folder first before uploading a new folder with the "Replace" option.

    I prefer the first approach to be honest.

  9. kulmann commented on Mar 20, 2024

    @kulmann
    Contributor

    Solutions I can think of:

    • Improve on our wording: "Replace" becomes "Merge" in case of an upload.
    • Delete the existing folder first before uploading a new folder with the "Replace" option.

    I prefer the first approach to be honest.

    Yes, I think the same. The "Replace" option in folder upload conflict handling should be named "Merge" instead. Doing a delete before uploading would open a can of worms for error handling (I'd expect a rollback for the deleted folder in case the upload goes wrong...)

  10. JammingBen commented on Mar 20, 2024

    @JammingBen
    Contributor

    I created #10640 to keep track of it. Which means I'm closing here as this has been resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Priority:p2-highType:Bug

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions