New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 873504 link

Starred by 4 users

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 3
Type: Feature


Show other hotlists

Hotlists containing this issue:
Launcher-Polish


Sign in to add a comment

Chrome OS Shelf Position Preference Does Not Sync

Reported by quittlel...@gmail.com, Aug 12

Issue description

UserAgent: Mozilla/5.0 (X11; CrOS x86_64 10718.71.2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.87 Safari/537.36
Platform: 10718.71.2 (Official Build) stable-channel auron_yuna

Steps to reproduce the problem:
1

1. Sign into the chromebook as a user profile
2. Once signed in, right click on the shelf.
3. Change the shelf position from bottom (default) to left or right.
4. Continue using the Chromebook long enough for all settings to sync (several days of periodic use)
5. Factory reset the Chromebook
6. Sign into the same account
7. Wait 20 minutes for all settings to be restored

What is the expected behavior?
The shelf position restores to the left/right side as previously set.

What went wrong?
The shelf position remained on the bottom and never restored to my previously set setting.

Did this work before? No 

Chrome version: 68.0.3440.87  Channel: stable
OS Version: 10718.71.2
Flash Version: Shockwave Flash 30.0 r0
 
Cc: treib@chromium.org abodenha@chromium.org osh...@chromium.org xiy...@chromium.org
Components: UI>Shell>Shelf
Labels: -Type-Bug Sync-Triaged Type-Feature
I suspect that this particular preference was simply never set up to sync, so this is a feature request for the ChromeOS UI rather than a bug in Sync.
Semi-randomly adding some ChromeOS UI folks, hopefully someone can triage this to the right place. Thanks!
Cc: msw@chromium.org
+msw

Shelf alignment should be initialized from sync when a user is newly added to the device. See [1] for more details.

I suspect that there is a race between the local alignment pref and synced version, causing the synced version not applied.

[1] https://cs.chromium.org/chromium/src/ash/public/cpp/ash_pref_names.cc?rcl=ae54e260d128790bdf4383ef0246606e19608460&l=245
Cc: tschumann@chromium.org
I couldn't repro with similar steps on my local linux-chromeos build at #583064:
1) Sign into a profile with --user-data-dir=/tmp/user1 --login-manager
2) Set left shelf alignment (see commit request&response in about:sync-internals)
3) Shutdown
4) Sign into the same profile as before with a different user-data-dir
5) Wait for prefs to sync, shelf is set to left alignment. (works as expected for me)

I'm not sure what would be different on device, +CC Tim for thoughts.

Shelf prefs are white-listed for foreign syncing (slightly special treatment by sync to support Chrome and Ash running in separate processes):
https://cs.chromium.org/chromium/src/chrome/browser/chromeos/preferences.cc?rcl=ee9ee6345abd0cfeb8a5b94446a278acdfe69e24&l=118

The relevant code should move to Ash, so Chrome isn't involved, but that's blocked by Issue 774657, see the code here:
https://cs.chromium.org/chromium/src/chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc?rcl=9d6f39a010b60dfa489615b80379f502421ea231&l=899
I'm not aware of any sync differences between ChromeOS and linux-chromeos environments.

What would be interesting to see: When you reproduce the problem, check out the Sync Node Browser on chrome://sync-internals/ and look for the preferences "shelf_alignment" and "shelf_alignment_local" in the "Preferences" and "Priority Preferences" folders.

Having the displayed data in this bug would help further investigations.
I'm not sure why, but my shelf_alignment does not reflect what I have locally.

I don't have anything shelf-related under Priority Preferences and I don't see shelf_alignment_local listed anywhere. Somehow, It says it hasn't sync'd my shelf_alignment preferences since last year.

Under Preferences > shelf_alignment

Title	shelf_alignment
ID	sZ:ADqtAZxjTVdlmu1V8xDf4aNLAftDRKRANkIPOjlcS0C0QKxQSSWR2yM+DhnpoPU7BbE3gSV9J+BWGPY1eUeEVne1qS5ppxu+WQ==
Modification Time	Sunday, September 10, 2017 at 5:41:54 PM
Parent	
Is Folder	false
Type	Preferences
External ID	0
{
  "BASE_SERVER_SPECIFICS": {},
  "BASE_VERSION": "1505061714204818",
  "CTIME": "Saturday, July 1, 2017 at 2:26:37 AM",
  "DIRTY_SYNC": false,
  "ID": "sZ:ADqtAZxjTVdlmu1V8xDf4aNLAftDRKRANkIPOjlcS0C0QKxQSSWR2yM+DhnpoPU7BbE3gSV9J+BWGPY1eUeEVne1qS5ppxu+WQ==",
  "IS_DEL": false,
  "IS_DIR": false,
  "IS_UNAPPLIED_UPDATE": false,
  "IS_UNSYNCED": false,
  "LOCAL_EXTERNAL_ID": "0",
  "META_HANDLE": "156",
  "MTIME": "Sunday, September 10, 2017 at 5:41:54 PM",
  "NON_UNIQUE_NAME": "shelf_alignment",
  "PARENT_ID": "",
  "SERVER_CTIME": "Saturday, July 1, 2017 at 2:26:37 AM",
  "SERVER_IS_DEL": false,
  "SERVER_IS_DIR": false,
  "SERVER_MTIME": "Sunday, September 10, 2017 at 5:41:54 PM",
  "SERVER_NON_UNIQUE_NAME": "shelf_alignment",
  "SERVER_PARENT_ID": "",
  "SERVER_SPECIFICS": {
    "preference": {
      "name": "shelf_alignment",
      "value": "\"Right\""
    }
  },
  "SERVER_UNIQUE_POSITION": "INVALID[]",
  "SERVER_VERSION": "1505061714204818",
  "SPECIFICS": {
    "preference": {
      "name": "shelf_alignment",
      "value": "\"Right\""
    }
  },
  "SYNCING": false,
  "TRANSACTION_VERSION": "1",
  "UNIQUE_BOOKMARK_TAG": "",
  "UNIQUE_CLIENT_TAG": "tfGKb03RNDkJJ9b12COo8yQA4fM=",
  "UNIQUE_POSITION": "INVALID[]",
  "UNIQUE_SERVER_TAG": "",
  "isDirty": false,
  "modelType": "Preferences"
}
I powerwashed my chromebook and my shelf preferences did restore this time.
I just enabled developer mode on the chromebook and my shelf preferences did not restore.
Components: Internals>Preferences
Status: Untriaged (was: Unconfirmed)
Re #4/#5: shelf_alignment_local isn't a synced preference, so it won't show up in chrome://sync-internals. That's expected.

It does indeed sound like there's a race between the two prefs: If the local version somehow gets set before the synced one comes in, then the synced one will be ignored. This does look related to bug 774657.
Owner: manucornet@chromium.org
Labels: -Pri-2 Pri-3
Status: Available (was: Untriaged)
Status: Assigned (was: Available)
Components: -UI>Shell>Shelf
Owner: ----
Status: Available (was: Assigned)
This sounds like an issue with the prefs syncing logic rather than the shelf UI per se? Removing Shelf component, marking as available.
Cc: manucornet@chromium.org
Components: UI>Shell>Shelf
The issue is with how the shelf UI uses its prefs; it's a rather weird setup with both a local (non-synced) and a synced pref, which are consolidated in a racy way. Syncing of the pref itself is working as intended.
Addinb UI>Shell>Shelf back, since this can't be fixed on the Sync side.

Sign in to add a comment