mirakel-android icon indicating copy to clipboard operation
mirakel-android copied to clipboard

Deleted tag restore after sync

Open sezuan opened this issue 10 years ago • 10 comments

With the new 2.6.0beta3 #438 seems to be fixed, but a issue with tags remains. Deleted tags will be readded with the second sync. The deleted tags appear in Mirakel right after the first sync.

sezuan avatar Jun 30 '14 05:06 sezuan

Thanks for reporting we will fix it soon

itadventurer avatar Jun 30 '14 08:06 itadventurer

In my setup (2.6.0 beta3) Mirakel does not download tags

ilvetz avatar Jul 03 '14 19:07 ilvetz

with 2.6.1 at least some tags still appear. Might this happens due to the identical date of adding and removing the tags? For an affected task 'task info' looks like this:

2014-06-29 11:59:20 Tags changed from 'FOO' to 'BAR'.                                                          
2014-06-29 11:59:20 Tags deleted.  

The identical date is caused by the initial taskd server import, however the order is preserved in all cases that I've checked.

sezuan avatar Jul 07 '14 06:07 sezuan

Hmm… This is very strange. For me everything is working. Could you please try this with the next Mirakel version. There we have fixed a related bug. Please reopen this issue if won't be fixed

itadventurer avatar Jul 13 '14 19:07 itadventurer

It still happens. When I sync twice (initual + extra) (almost?) all tasks will be modified, with at least:

  • deleted tags will be set
  • Annoations will be deleted and add again (in one step)
  • Modified date will be updates

for instance:

2014-07-14 12:54:10 Annotation 'Bugfixing' deleted.
                    Annotation of 'Bugfixing' added.
                    Tags set to 'FOO,BAR'.
                    Modified changed from '2014-07-14 08:22:00' to '2014-07-14 12:54:10'.

I can try to setup a test server.

sezuan avatar Jul 14 '14 11:07 sezuan

That's bad :( I will take a look on it…

itadventurer avatar Jul 14 '14 17:07 itadventurer

The annotations change is cause by our implementation. Someday we will fix this. Due the a change the modification date is updated(as required from the protocol). The change of tags is something what should not happen. I am not able to reproduce this. It would be great to get explicit steps to reproduce this. Something like: setup the account add a task in task(task add Test) sync to taskd sync from mirakel add a tag in taskd(task 1 mod +foo) sync to taskd sync from mirakel and so on

weiznich avatar Jul 14 '14 20:07 weiznich

weiznich, can you elaborate: "The annotations change is cause by our implementation."? I experience strange annotation duplication (even multiplication) when I add an annotation via shell task client, then sync, and do a mirakel sync.

This is the part of taskd log where I sync with mirakel:

2014-07-22 12:08:48 [367] patch remove annotation_1406029945 2014-07-22 12:08:48 [367] patch remove annotation_1406029946 2014-07-22 12:08:48 [367] patch remove annotation_1406029947 2014-07-22 12:08:48 [367] patch remove annotation_1406029948 2014-07-22 12:08:48 [367] patch add annotation_1406030270=annotationtext 2014-07-22 12:08:48 [367] patch add annotation_1406030271=annotationtext 2014-07-22 12:08:48 [367] patch add annotation_1406030272=annotationtext 2014-07-22 12:08:48 [367] patch add annotation_1406030273=annotationtext

Also, there are a lot of "Branch point: 23612341-0773-4d06-86a0-6c2579ce6dde --> 420" entries, and when I sync back with shell task client, I get many "updates" of tasks which I haven't modified in mirakel.

It looks to me as if Mirakel does not fetch the newest changes, but instead writes it's own db back to the server regardless of modification timestamps.

I'm using version 2.6.2.

epistemery avatar Jul 22 '14 12:07 epistemery

Have you steps to reproduce this annotation duplication?

Annotations are threated as description in mirakel. This means all annotations are saved in one long string. Therefore the dates when the annotation was added, are lost and replaced by the date on which the task was last modified. We see currently no easy way to fix this.

Also mirakel mark tasks sometimes as changed, but there is no change(as you mention). This could be caused by different things:

  1. Make a change and revert the change.
  2. Sometimes without any cause. Again we don't know why, but this should be gone as soon as we rewrite the ui(See #451 ).

weiznich avatar Jul 22 '14 14:07 weiznich

I did not revert any changes. I just set up a test environment and as of now I am not able to reproduce the problem. Sync problems are the worst to diagnose. What I can say so far is that the error happened when I set autosync to every five minutes in Mirakel on two android devices and also a cronjob (*/5 * * * *) sync on one linux workstation. Maybe that's not a good idea :/

I tried to sync my mirakel again and the duplication didn't happen again. But there are unpredictable syncs without me having modified anything. Plus on time I changed a due: tag using the task client and it wasn't updated in Mirakel.

Are there any suggestions for systematically testing sync scenarios?

epistemery avatar Jul 23 '14 12:07 epistemery