Complete sync on Android but transactions not appearing on website

  • 1
  • Problem
  • Updated 2 weeks ago
Hello,

All are in the title. I enter all my transactions in my Android device. It always says sync complete but once I go to the website, I noticed transactions are one week away from today.

Thank you,
Photo of Asgardia

Asgardia

  • 5 Posts
  • 1 Reply Like

Posted 9 months ago

  • 1
Photo of Alex Park

Alex Park, Official Rep

  • 243 Posts
  • 48 Reply Likes
Hi there,

Thanks for your message, and sorry for the missing transactions! It sounds like your phone may not be syncing its transactions to our servers properly. Would you mind contacting us at support@goodbudget.com with your Goodbudget household email address so we can take a look at your household and see what might be happening?

In the meantime, would you try doing a manual sync to see if that resolves the issue? You can manually sync on Android by going to the Envelopes tab, and choosing "Sync" from the overflow menu. Make sure you're on a stable internet connection when you do this or the sync may fail midway.

Photo of Asgardia

Asgardia

  • 5 Posts
  • 1 Reply Like
Thank you for your answer :) I'm already used to manually sync all the time and it always show "sync complete". It always worked before. I think I gonna write to this email address then. Thanks :)
Photo of Asgardia

Asgardia

  • 5 Posts
  • 1 Reply Like
Hi, see my comment below.
Photo of Asgardia

Asgardia

  • 5 Posts
  • 1 Reply Like
Hello, So I have news about this problem. I didn't find any solution during those months. But I was always managing myself to solve it manually all the time. This is a bug or a missing feature and I'm going to explain everything here.

As I see the issue is persisting even in the last version of Goodbudget.

How does it work?
I finally know that the sync issue happen when I edit transactions offline. Then when I come online they are not synced back to the web server. Sometimes it works though so I think it's a bug not a missing feature.

How did I solve it before?
I noticed that when I update (or create) a transaction on my android app again then one transaction is uploaded to the web. It's not the updated (or created) transaction but the most recently not synced transaction. So what I do everytime the transaction gap happen : I had to make enough transactions modification while having internet connection.
I mean if 20 transactions are missing on the web. I must make 20 modifications on a random transaction and sync 20 times to get it shown on the web.

Technical info/solution
I'm a developer and today I had some time to dig about it. I've seen that the app was not intended to sync multiple transactions at a time when it's online. When it syncs, it only sync single transaction (from the app to the web) so that's why I had to make 20 modifications of transaction to trigger the missing 20 transactions sync on the web.
I decompiled the apk the issue happen here in this class com/dayspringtech/envelopes/sync/SyncTransactions.java in the function that return a PostStatus . There is a while loop there that should walk through all unsynced transactions from Sqlite and send it to the server. But this loop will always work only one time. Somewhere in this function there is this code
if (c != null) {
if (!c.isClosed()) {
c.close();
c = null;
} }
So after the first execution of the loop, it immediately closes the Sqlite cursor so the following transactions are not synced anymore. I temporarily deleted this code, recompiled the apk and reinstalled it on my device. IT WORKED IMMEDIATELY. The app now syncs all missing transactions from the device to the web.

So I'm using this pached app for now but I will not be able to use your updates so I hope it will be fixed in next release.

Thanks!
(Edited)
Photo of Alex Park

Alex Park, Official Rep

  • 238 Posts
  • 47 Reply Likes
Hi Asgardia,

Thanks for your digging and for sharing your detailed findings with us! I'm not well-versed enough in programming to understand exactly what information you've provided, but I'll be sure to pass your comment on to our developer to see what we can do with your research.

Thanks again!