desktop icon indicating copy to clipboard operation
desktop copied to clipboard

3.4.2 conflicts on every edit

Open ColinFinck opened this issue 4 years ago • 45 comments

I was affected by #4016, and as a result of that, I've updated all clients on all machines to 3.4.2, updated the server from 22.0.0 -> 22.1.1 -> 22.2.3 -> 23.0.0 -> 23.0.1, and followed https://github.com/nextcloud/desktop/wiki/Fix-bug-invalid-modification-date to fix the invalid modification dates on the server.

Unfortunately, I'm now affected by an even more severe bug:

Steps to reproduce

  1. I create a new file "test.txt" and write a single letter "a" into it, and hit Ctrl+S to save. I even wait until the Nextcloud client shows it is synchronized.
  2. With the editor still open, I add a second letter "b" and hit Ctrl+S again.
  3. The Nextcloud client shows "Conflict: Server version downloaded, local copy renamed and not uploaded", I get a "test (conflicted copy 2022-02-03 084856).txt", and Nextcloud asks me what version to keep. Even worse, Nextcloud first overwrites my just edited version of the file by the server copy (which only contains "a"). My editor notices that and asks me whether to reload the file. If I hit "Yes", my latest edit is gone.

This is perfectly reproducible on two Windows 10.0.19044 systems (connected to the same Nextcloud account). I'm using a traditional setup with a single Nextcloud folder that is locally synchronized (no virtual folders).

Expected behaviour

Nextcloud uploads the newly edited file without a notice, as it did for years.

Actual behaviour

Nextcloud replaces my edits with the last copy from the server and asks for conflict resolution, making work inside the Nextcloud folder impossible.

Client configuration

Client version: 3.4.2 Operating system: Windows 10 (10.0.19044) OS language: German Installation path of client: C:\Program Files\Nextcloud

Server configuration

Nextcloud version: 23.0.1 Storage backend (external storage): local

ColinFinck avatar Feb 03 '22 08:02 ColinFinck

Hello.

I have the same problem.

I hope it is resolved quickly, it is not comfortable to work with this error.

Greetings.

sagitariozod avatar Feb 03 '22 15:02 sagitariozod

As a temporary solution I have installed the client version 3.4.0-RC1 (3.3.81) and it does not have this bug.

All versions higher than this have the bug.

Greetings.

sagitariozod avatar Feb 03 '22 16:02 sagitariozod

I can reproduce this, but only in a folder that is shared with other people. It might simply not happen on a file that is not shared?

Steps were similar:

  • create a file, add a line of text
  • save in a shared folder
  • wait until the green tick shows up (file is synced)
  • add another line of text and hit save
  • wait for sync - conflict file shows up, your editor warns your file was changed.

Debug archive created, accessible to the engineers: https://cloud.nextcloud.com/f/5575442

jospoortvliet avatar Feb 04 '22 12:02 jospoortvliet

so this is a bug of bulk upload people with the ability to reproduce the bug, could you share your logs with me ? I think I have the time to give this a look quickly

mgallien avatar Feb 04 '22 12:02 mgallien

At this moment I can't send the debug file, but I confirm that it happens in shared and unshared folders.

Greetings.

sagitariozod avatar Feb 04 '22 16:02 sagitariozod

I have a situation here as mentioned in: 3.4.0 keep synchronizing files after upgrade

Went back to 3.3.6 in order to wait for the "storm"to pass. After seeing 3.4.2 available I was lured to update the client. No I am trying to solve it issues with the aid of: https://github.com/nextcloud/desktop/wiki/Fix-bug-invalid-modification-date I've encountered some problems as the environment in which the mentioned scripts are not defined. Looking for solutions I came here and want to offer my help as test case ( and rubber duck). I use client 3.4.2 on win10? and server 23.0.0. Where and how can I help I made a backup of the nd data directory and put the server in maintenance mode.

balvie avatar Feb 05 '22 10:02 balvie

I see that @jospoortvliet has posted a debug archive. Is there anything else you need from me as the original reporter? I'm here to help, but I had a look into my debug archive and it contains a lot of personal data. Hence, it would be good to know what you're looking for exactly.

ColinFinck avatar Feb 07 '22 07:02 ColinFinck

@ColinFinck that should be fine, thanks and sorry for the troubles in case I would need feedback to confirm the problem is solved, are you able to test with a specific version I would provide ?

mgallien avatar Feb 07 '22 15:02 mgallien

Hello @mgallien, I could test the specific version you mention.

If you want you can send it to me.

Greetings.

sagitariozod avatar Feb 07 '22 16:02 sagitariozod

@ColinFinck @jospoortvliet @sagitariozod applying this pull request to my server v23 https://github.com/nextcloud/server/pull/30999 is enough to fix the issue for me

mgallien avatar Feb 07 '22 16:02 mgallien

sorry for the delay analyzing this issue

mgallien avatar Feb 07 '22 16:02 mgallien

@mgallien I have just applied https://github.com/nextcloud/server/pull/30999 to my Nextcloud 23.0.1 instance, but unfortunately it doesn't fix the problem for me. I still get a conflict every time I edit an existing file again.

ColinFinck avatar Feb 07 '22 17:02 ColinFinck

@ColinFinck I will need your logs I could no longer reproduce the conflicts after applying the server patch

mgallien avatar Feb 08 '22 09:02 mgallien

I have replaced on server the file OC_Helper.php but the problem still persist.

sagitariozod avatar Feb 08 '22 13:02 sagitariozod

I have replaced on server the file OC_Helper.php but the problem still persist.

@sagitariozod I am not sure what you did but in any case I cannot dig further without logs of the desktop client

mgallien avatar Feb 09 '22 08:02 mgallien

@mgallien en teoría estaba aplicando el parche

@mgallien I have just applied nextcloud/server#30999 to my Nextcloud 23.0.1 instance, but unfortunately it doesn't fix the problem for me. I still get a conflict every time I edit an existing file again.

@mgallien in theory I was applying the patch that you indicated, not if what I have done is correct.

I'll send you the desktop client logs as soon as I can find time to sanitize them and remove sensitive information.

Apologies for my English, I use the google translator.

Greetings.

sagitariozod avatar Feb 09 '22 10:02 sagitariozod

@ColinFinck I will need your logs I could no longer reproduce the conflicts after applying the server patch

I created a new user for that on my Nextcloud server and installed Nextcloud Desktop 3.4.2 on a Windows 10 machine that didn't have any exposure to Nextcloud before. I could again reproduce the problem. Here are the redacted and combined logs: https://gist.github.com/ColinFinck/c0dca5d36bf83d5ae90558adf47c9f1f

ColinFinck avatar Feb 09 '22 10:02 ColinFinck

@mgallien en teoría estaba aplicando el parche

@mgallien I have just applied nextcloud/server#30999 to my Nextcloud 23.0.1 instance, but unfortunately it doesn't fix the problem for me. I still get a conflict every time I edit an existing file again.

@mgallien in theory I was applying the patch that you indicated, not if what I have done is correct.

I'll send you the desktop client logs as soon as I can find time to sanitize them and remove sensitive information.

Apologies for my English, I use the google translator.

Greetings.

What I was trying to say is that I really need the logs because without them I am afraid I cannot fix the bug. Indeed, the exact steps you did is also very important because that may enable to more easily understand the problem

no problem for the communication and please apologize any troubles I am also not an English native speaker

mgallien avatar Feb 09 '22 10:02 mgallien

@mgallien can you please confirm that https://gist.githubusercontent.com/ColinFinck/c0dca5d36bf83d5ae90558adf47c9f1f/raw/499c8269083e268ca35361290f84251afaa4f47b/nextcloud-desktop-4243-logs-redacted-combined.txt has enough information to debug this?

solracsf avatar Feb 09 '22 10:02 solracsf

I can report the same issue on linux as well, with the latest release 3.4.2, Server-Version: 23.0.1, later I will provide a debug log.

rwese avatar Feb 09 '22 14:02 rwese