MirakelX / mirakel-android

Easy task management for professionals
http://mirakel.azapps.de/
385 stars 117 forks source link

Taskdoubling while sync to taskd #267

Closed weiznich closed 9 years ago

weiznich commented 10 years ago

Sometimes there is a task doubling when syncing with taskd

weiznich commented 10 years ago

I've tried to reproduce this by use the Sync-test. But this did not help. Maybe its fixed. If not, please reopen.

krohn commented 10 years ago

I have the same issue, on a fresh Mirakel-Install, tasks are synced down to Mirakel. After first sync up to taskd, my tasks are doubled (but without proper priority). This seems to happen only on the first sync, because after deleting the doubled tasks in taskd, they are not recreated.

itadventurer commented 10 years ago

Now I've tried the sync and everything worked perfectly. Used versions:

# Client
ζ task --version
   2.4.0.dev
# Server
μ taskd --version
   taskd 1.1.0.dev b60355b
# Mirakel: Dev-version

@krohn Could you please tell us which versions you use?

krohn commented 10 years ago

I'm using:

weiznich commented 10 years ago

I've tried again to reproduce this without any success. The only thing left which could maybe cause this is the android version. I've tested with android 4.4 and 2.2. Which version did you use? And if you did deleted the duplicated tasks did you notify of the uuid's for two tasks where the same or did they differ?

krohn commented 10 years ago

It's Android 4.4.2 OmniROM (This is relevant?) Regarding the UUIDs, I'll have to check the taskd.log, or is there something like a logging in Mirakel?

krohn commented 10 years ago

I still can reproduce it:

Is there a way to see the UUID in Mirakel?

weiznich commented 10 years ago

To get the uuid's in mirakel you must query the database. To do this you must open a shell, switch to root, cd to /data/data/de.azapps.mirakelandroid/databases/. Then open the database with sqlite3 Mirabel.db. After that type Select name, uuid from tasks; to get all tasknames and uuid's. Where are the tasks doubled? Only in taskd or also in task?

krohn commented 10 years ago

Doubled after sync from Mirakel to Taskd, in Taskd (and all other task-clients) the tasks appear twice. In Mirakel the appear only once.

weiznich commented 10 years ago

I've tried again to reproduce this without any success. The only thing I've seen is that sometimes tasks are sync which should not change anything. Maybe I should try this with omnirom again.

Maybe it would also be useful to see what taskd is sending in this first sync. To get this you must either compile Mirakel from the scratch and take a Logcat (the entry is only shown if it was compiled in debug mode). The second possibility is to patch the source of taskd and take the log there. To do this add in the file src/TLSServer.cpp between line 132 and 133 the following line: level=2; After that start the server not on the demon mode and you will see the tasks which are synced in your shell. With such a log we may be able to debug this furthermore.

krohn commented 10 years ago

Unfortunately, I have no idea how to cross-compile an Android app on a Mac, so currently no option :-( I'll check with taskd. Plus: I'll create blank second new account for the sync so we say if I have problem due to something in my old *.data.

Sidenote: Maybe one day Mirakel optionally writes debug-infos of the last sync onto my SD Card. One would have an log of the last sync, with would make thinks like this more easy...

weiznich commented 10 years ago

Compiling should be simple. You must install the android-SDK(see [1]) , gradle (see[2]) and maybe got to get tho code. About the SDK: you will need only the sdk-tools. After unzip the Tools run the android-executable from sdk/tools and install all tools and everything with android 4.4.2. About gradle: You will need version 1.9 not 1.10. After setting up these things open shell in the source-dir and make sure that gradle and the the SDK/tools dir is in your path. Then type export ANDROID_HOME=/path/to/SDK and gradle build. After the building is finished goto build/apk and install one of the debug builds. While making a sync you should be able to get a logcat with adb logcat(of the device is connected to your PC)

About the sidenote. This was there without option in the first builds which support the sync. So I will take a look how to restore this.

[1] http://developer.android.com/sdk/index.html?utm_source=weibolife [2] http://www.gradle.org/downloads

weiznich commented 10 years ago

We have uploaded a new beta-release. This contains hidden developer-settings. To activate this settings, think of android and tap several times on the version number. In these settings are a option to dump the json which is send and received by mirakel. It would be great to get some log.(Logs are in /sdcard/mirakel/)

weiznich commented 10 years ago

This is the last issue which is blocking the next release. So it would be great to get some logs to get this fixed as soon as possible.

krohn commented 10 years ago

Maybe I find the time tonight. I'll let you know. Do you want us to send the logs to mirakel@azapps.de ?

2014-02-09 20:26 GMT+01:00 Georg Semmler notifications@github.com:

This is the last issue which is blocking the next release. So it would be great to get some logs to get this fixed as soon as possible.

Reply to this email directly or view it on GitHubhttps://github.com/azapps/mirakel-android/issues/267#issuecomment-34583319 .

Karsten Krohn, Ilmer Drift 5a, 21423 Winsen karsten@krohn.io

Tel: +49-4171-608859, +49-174-1459713 Fax: +49-4171-201345

weiznich commented 10 years ago

mirakel@azapps.de or here would be ok.

krohn commented 10 years ago
weiznich commented 10 years ago

Seems to be my mistake, that there are no logs. I've fixed that, so now there should be logs in the files. Files should be again under /sdcard/mirakel, but now referenced by date and .tw_[up/down].log I've uploaded a new testbuild which contains this fixes to [1]

[1]http://mirakel.azapps.de/releases.html

krohn commented 10 years ago

I just send some logs to mirakel@azapps.de. Hope they'll help.

itadventurer commented 10 years ago

So I put this on the „wontfix“ list for now. If it happens again please let us know