After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 794645 - Bookmarks lost after upgrade
Bookmarks lost after upgrade
Status: RESOLVED FIXED
Product: epiphany
Classification: Core
Component: Bookmarks
3.28.x
Other Linux
: Normal normal
: ---
Assigned To: Epiphany Maintainers
Epiphany Maintainers
Depends on:
Blocks:
 
 
Reported: 2018-03-24 03:41 UTC by Michael Gratton
Modified: 2018-03-26 05:16 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Reorder search engines migrator to ensure it does not fail (2.22 KB, patch)
2018-03-25 20:58 UTC, Michael Catanzaro
committed Details | Review
Always run profile migrator from source root in developer mode (891 bytes, patch)
2018-03-25 20:58 UTC, Michael Catanzaro
committed Details | Review

Description Michael Gratton 2018-03-24 03:41:56 UTC
After upgrading to Ephy 3.27.90, and continuing with 3.28.0.1, my bookmarks have disappeared. There is one called "" (U+0003) with a reasonably random seeming link, but maybe I accidentally added that after the upgrade? This also happened from 3.24 to 3.26.
Comment 1 Michael Catanzaro 2018-03-24 20:36:33 UTC
Did you at any point upgrade to an earlier 3.27 release? There was bug #792683, but that was fixed in 3.27.90 and should not have affected you if you upgraded straight from 3.26 to 3.27.90.

Any chance you have a backup of your original bookmarks file?

To debug, we need to be able to reproduce, that means (a) copy a bookmarks.gvdb that triggers the migration bug into ~/.config/epiphany, (b) delete ~/.config/epiphany/.migrated, (c) start epiphany from the command line so that we can see if there are any warnings or criticals during the migration. If you've got a bookmarks file that triggers the issue, or are able to figure out how to trigger it otherwise, then that would be great.
Comment 2 Michael Catanzaro 2018-03-24 20:49:43 UTC
Hm, I can reproduce a problem using an old bookmarks.gvdb from one of my backups:

$ flatpak run org.gnome.Epiphany 

(ephy-profile-migrator:7): GLib-CRITICAL **: 15:38:59.163: the GVariant format string '(x&s&sxbas)' has a type of '(xssxbas)' but the given value has a type of '(xssdbas)'

(ephy-profile-migrator:7): GLib-CRITICAL **: 15:38:59.163: g_variant_get: assertion 'valid_format_string (format_string, TRUE, value)' failed
Failed to run the migrator process, Web will now abort.

But this doesn't cause any bookmarks to be deleted, it instead causes epiphany to crash on start. So the bug  I'm looking at seems different from yours.
Comment 3 Michael Catanzaro 2018-03-24 21:29:56 UTC
In my case, the problem is caused by migrator 17, the search engines migrator. It tries to convert old smart bookmarks to search engines, but this blows up because we are only partway through the bookmarks migration (migrators #12 and #24). In effect, migrator 17 now depends on migrator 24 running first. I'm not sure, but maybe we can move it to later in the migration.

I think your problem must be different, though.
Comment 4 Michael Catanzaro 2018-03-24 21:41:33 UTC
(In reply to Michael Catanzaro from comment #1)
> Did you at any point upgrade to an earlier 3.27 release? There was bug
> #792683, but that was fixed in 3.27.90 and should not have affected you if
> you upgraded straight from 3.26 to 3.27.90.

Ah wait, I missed the 3.26 branch history here. That migrator was backported to 3.26... which I think I'll never allow again, that turned out to be a big mistake. So that bug explains how you lost your bookmarks during the 3.24 -> 3.26 migration. Still doesn't explain what happened to you during the 3.26 -> 3.28 migration, though.
Comment 5 Michael Catanzaro 2018-03-25 20:58:20 UTC
The following fixes have been pushed:
873f445 Reorder search engines migrator to ensure it does not fail
4d78f0d Always run profile migrator from source root in developer mode
Comment 6 Michael Catanzaro 2018-03-25 20:58:23 UTC
Created attachment 370125 [details] [review]
Reorder search engines migrator to ensure it does not fail

The search engines migrator relies on EphyBookmarksManager, so we need
to move it after the bookmarks timestamp migrator or it will fail. This
fixes upgrades from old (pre-3.24) versions of Epiphany.
Comment 7 Michael Catanzaro 2018-03-25 20:58:26 UTC
Created attachment 370126 [details] [review]
Always run profile migrator from source root in developer mode
Comment 8 Michael Catanzaro 2018-03-25 20:59:47 UTC
I've fixed the only problem I could find, but I'm pretty sure whatever you hit was a different issue. So if you're able to find a way to reproduce, please to reopen.
Comment 9 Michael Gratton 2018-03-26 05:16:43 UTC
(In reply to Michael Catanzaro from comment #8)
> I've fixed the only problem I could find, but I'm pretty sure whatever you
> hit was a different issue. So if you're able to find a way to reproduce,
> please to reopen.

I don't have a backup, so yeah I guess that will have to do. Thanks for looking into it. Apologies for the late reply, was out over the weekend.