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.

Dubious overwrite logic with etag / server side conflict handling #3262

Closed

Description

@PVince81

See these:

apps/files/src/mixins.js|207 col 61| this.$_ocUpload(file, item.fullPath, exists.etag)
apps/files/src/mixins.js|237 col 59| this.$_ocUpload(files[i], files[i].name, exists.etag)

it seems to be passing in an etag but the method $_ocUpload takes an overwrite boolean as parameter.

It is likely that folder upload is not properly processing overwrites, unless it just works "by chance".

@LukasHirt FYI

Activity

  1. PVince81 commented on Mar 25, 2020

    @PVince81
    ContributorAuthor

    Compared to OC 10, it also seems that the logic is not relying on the 412 or 409 error codes on upload to trigger the overwrite dialog.

    I'll tag this as bug now, we need to revise the way how we detect conflicts and manage concurrency.

    Here's an example case that is not handled properly:

    1. Create a folder "conflict"
    2. Open the folder
    3. Open another browser tab and navigate into the folder "conflict" there as well
    4. In the first browser tab, upload a file "test.txt"
    5. In the second browser tab, upload the same file "test.txt"

    Expected result

    Conflict dialog "do you want to overwrite ?", then confirming would attempt the upload again.

    Actual result

    image

  2. changed the title [-]Dubious overwrite logic with etag[/-] [+]Dubious overwrite logic with etag / server side conflict handling[/+] on Apr 23, 2020
  3. added
    Priority:p2-high
    and removed
    Priority:p3-medium
    on Dec 3, 2021
  4. tbsbdr commented on Jun 28, 2022

    @tbsbdr

    needs to be checked with uptodate ocis and oc10 backends.

  5. JammingBen commented on Aug 1, 2022

    @JammingBen
    Contributor

    Current behavior for both backend is that the second tab will overwrite the uploaded file without showing any kind of conflict dialog. I guess the expected behavior is that this dialog shows though, right @kulmann @tbsbdr ?

  6. tbsbdr commented on Aug 1, 2022

    @tbsbdr

    👍 correct

  7. self-assigned this
    on Aug 1, 2022
  8. tbsbdr commented on Sep 21, 2022

    @tbsbdr

    current behaviour is:

    closing as current behaviour is good enough - avoids dataloss 👍

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:Bugfeature:files

Type

No type

Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions