-
-
Notifications
You must be signed in to change notification settings - Fork 27
Sometimes messages are displayed twice #567
Comments
This smells like a core problem. |
I'm not sure which component writes to the local database. And if there is a check before adding a "new" message, if there is already a message with the same server_uid. |
yip, if the double entries are in the database, this seems to be a core problem, indeed. would be great to get some hints about how to reproduce this, however :) @nicodh thanks for filing this issue :) |
So far I have no idea how this happened. I sometimes start DeltachatDesktop as "normal application" from the applications folder (downloaded as dmg) and sometimes via "npm start" in the deltachat root folder. But this did not cause any problems so far. And as you see in the screen, the first message from holger is duplicated, the second not... So what would happen if both instances are open at the same time, writing to the same database. Could that result in a kind of "race condition"? But I'm not sure if that was the reason here, I don't think that I opened both instances at the same time, just mentioned it that this "might" have happened... |
@nicodh thanks for explanations, yip sth. as a race condition is reasonable. i assume this is a multi-device and/or multi-thread issue. seems as if, for whatever reason, messages pop up in different threads watching different folders before they are inserted to the database (when the insert is done, this could not happen as the message-id is checked). reasons for that may be related to a second device moving the message. if these assumptions go into the right direction, the doubled messages will differ in the server_folder and server_uid column - can you confirm this? |
i tried to explain in #569 what may have happened. |
I can see in the sqlLite database that there are multiple entries for messages with the same server_uid in the msgs table
The text was updated successfully, but these errors were encountered: