enakada / foxy-manga-reader

Manga reading add-on for Mozilla Firefox
Mozilla Public License 2.0
6 stars 1 forks source link

Still having issues with Sync #9

Closed magecu closed 6 years ago

magecu commented 6 years ago

I had a little more time to experiment with sync and there are still some issues.

Approach 1:

  1. I have deleted my sync account and synced everything except Add-ons.
  2. Then I created a new local account and synced it with the new clean online account.
  3. Added Foxy manga reader.
  4. Imported the mangas from a backup.
  5. Then I enabled synchronization of the addons. (after importing mangas)
  6. Started the sync manually a couple of times.
  7. Deleted the local account created a new account and synced it with the online account.
  8. No mangas were synced in this case.
  9. No further sync after adding or removing a manga.

Approach2:

  1. I have deleted my sync account and synced everything except Add-ons.
  2. Then I created a new local account and synced it with the new clean online account.
  3. Added Foxy manga reader.
  4. Then I enabled synchronization of the addons. (before importing mangas)
  5. Imported the mangas from a backup.
  6. Started the sync manually a couple of times.
  7. Deleted the local account created a new account and synced it with the online account.
  8. Only a portion of the mangas were synced.
  9. No further sync after adding or removing a manga.

In both cases I have checked about:sync-log. No errors were reported.

enakada commented 6 years ago

Hi there.

Can you provide me more information about your tests?

  1. What Firefox version are you using?
  2. Do you mind posting your backup file?

Deleted the local account created a new account and synced it with the online account.

  1. By 'deleted' do you mean you disconnected from the sync account? Did you remove Foxy after that?

Only a portion of the mangas were synced.

  1. Do you have any Mangafox bookmark in the backup file?

No further sync after adding or removing a manga.

  1. What did you mean by that? Did you connect to your sync account on another device or did you just check the 'last sync' information?
magecu commented 6 years ago
  1. Firefox version: 58.0.1

  2. File is attached foxy-manga-reader-201824.zip

  3. By delete local account I mean starting Firefox with "Firefox -P", then deleting the local account and creating a new clean one, without any bookmarks addons or other local settings. Then syncing with the new online account.

  4. Yes there are quite a few fanfox/mangafox bookmarks.

  5. I removed (or added) a manga from Foxy and then manually run the sync from firefox. Then I deleted the local account "Firefox -P" and synchronised with the online account. The removed manga was still present, like wise an added manga would not be present.

enakada commented 6 years ago

Thank you! I will run some tests to see if I can find the problem.

magecu commented 6 years ago

If there is anything else you need, just ask. I know how hard it is to reproduce a bug without enough information.

enakada commented 6 years ago

In both cases I have checked about:sync-log. No errors were reported.

Did you check about:sync-log between steps 6 and 7? Can you check it for me to see if I'm on the right track?

I found a problem with the size of the data to sync. It worked fine with my list, but I got problems when syncing your list.

1518011110160   Sync.Engine.Extension-Storage   ERROR   Syncing foxy-manga-reader@enakada: request failed: Error: HTTP 507; Error: HTTP 507 Insufficient Storage: Resource access is forbidden for this user (Maximum bytes per object exceeded (79375 > 16384 Bytes.) (resource://services-common/kinto-http-client.js:2354:21) JS Stack trace: formatResponse@kinto-http-client.js:2377:21 < processResponse@kinto-http-client.js:2352:14

Basically, it seems there is a size limit (16kb) for each object saved to the sync storage. For now, Foxy saves a single array with all bookmarks:

bookmark_list: []

I will have to redesign the storage which is a major change on how every part of the add-on works. That will take some time, because I have to make sure I won't break everyone's list during the upgrade. I will start working on that after releasing v0.5.3!

magecu commented 6 years ago

I will get you the data as soon as I can, but it might take me a couple of days, depends on how bussy I will be in the next few days. :)

enakada commented 6 years ago

No problem! I just want to confirm if there is anything else preventing you from syncing your manga. Thanks for all your help! :)

magecu commented 6 years ago

Yes you are on the right track. I also got this error, I just had to wait a little bit longer for the errors to populate, I even got the error from the original sync:

1517814518939 Sync.Engine.Extension-Storage ERROR Syncing foxy-manga-reader@enakada: request failed: Error: HTTP 507; Error: HTTP 507 Insufficient Storage: Resource access is forbidden for this user (Maximum bytes per object exceeded (22503 > 16384 Bytes.) (resource://services-common/kinto-http-client.js:2354:21) JS Stack trace: formatResponse@kinto-http-client.js:2377:21 < processResponse@kinto-http-client.js:2352:14

Sorry that it took me so long to check.

P.S.: BTW I am currently saving every so often an export of the bookmarks to a synced folder. So I am not in any danger of loosing my reading progress. :)

enakada commented 6 years ago

Yes you are on the right track. [...] Sorry that it took me so long to check.

Don't worry and thank you so much for your help! I've finished redesigning the storage and everything seems to be working as intended now. As soon as I finish testing some new features I will be releasing Foxy v0.6.0.

I will start working on that after releasing v0.5.3!

I decided to include some new features on the next release, thats why I will be skipping v0.5.3.

BTW I am currently saving every so often an export of the bookmarks to a synced folder. So I am not in any danger of loosing my reading progress. :)

Oh, thats great! I've done multiple tests after redesigning the sync storage, but it doesn't hurt to have a backup ready. :)