The Linux Page

Chrome Auto-update Feature & the "Could not create download directory" error

A Bug in Chrome Ubuntu—how a feature becomes a bug

The Ubuntu version of Chrome has a way to auto-restart itself which does not hide the window or loses your existing browsing. However, it clearly quits the current instance and starts a new one (well, technically, it probably starts the new instance first, grab hold of the windows, then quit the old instance).

First bug, when that happens, the Gnome icon will now open a new instance and not know anything about the old instance. In other words, if you use the icons to navigate between your applications, Chrome fails whenever it gets updated that way.

The dot under the Gnome Icon disappears on auto-restart.

If it were just that, I would say, well... you just have to restart when such an upgrade happens. You can use the special settings that says "Continue where you left off" (in the Advanced Settings under the On Startup section). That way restarting is relatively painless.

However, there is a really nasty bug when that auto-restart happens. It prevents the browser from accessing various folders (maybe because they are locked by the previous instance and the new one can't obtain its own lock and that part fails big time...) What that means is:

  • The browser loses the ability to record all history;
  • Installing Extensions fails with the error "could not create download directory";
  • Changes to the settings are likely to be lost after a restart.

These are those I noticed. There may be other features that fail in that situation.

I reported the bug on launchpad. I do not know whether this is the right location for such a bug report, but it's better to have it somewhere, at least. I'll update this post with a proper link if it gets moved to another platform and I'm notified of such an event.

It very looks like this is a problem in snapd. For now, we are told to run the following command to set a flag which should make snapd try harder at not losing the link to Gnome:

$ snap set core experimental.refresh-app-awareness=true

As we can see, they have some code in place already, but it's not yet made 100% official.