Physical Web Auto-enable behavior on iOS interacts poorly with Finch |
||||||||||
Issue descriptionChrome Version: 58.0.3021.0 (ToT) OS: iOS The Physical Web feature allows Chrome to scan for nearby devices broadcasting URLs and surface them within the browser. The first time the browser is launched, we detect whether conditions permit us to auto-enable the preference. If not, the preference is disabled. Except, it doesn't actually check the FIRST time the browser is launched, because the Finch configuration hasn't been synced yet and the Physical Web auto-enable logic is tied to the PhysicalWebEnabled flag. So it will actually check and possibly auto-enable on the second launch. The auto-enable check requires that Chrome is authorized to use your location. Since the check is only run once on the second launch, it's likely that the user has not authorized the app yet. To give users a chance to meet the auto-enable conditions before the feature is explicitly disabled, the check should not disable the preference when the conditions are not met. This will allow the auto-enable check to run on subsequent launches. We should definitely fix this before the PhysicalWebEnabled flag is removed. When that happens, the auto-enable logic will run only on the first launch, giving the user even less opportunity to authorize location.
,
Feb 22 2017
Oh I understand. It's because our one-time-check is currently gated on first-time-flag-is-enabled. Once/if we change to be first-chrome-launch, we are impacted more severely by this bug.
,
Feb 23 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/0e3b410bacaa28cde0c2be4c2eba96451c6ca72a commit 0e3b410bacaa28cde0c2be4c2eba96451c6ca72a Author: mattreynolds <mattreynolds@chromium.org> Date: Thu Feb 23 19:01:27 2017 Extend Physical Web iOS auto-enable behavior beyond first launch. On Chrome start, we check whether the device state permits us to auto-enable the Physical Web feature to perform foreground scanning for nearby Bluetooth LE devices broadcasting URLs. Previously, if the auto-enable conditions were not met, the Physical Web preference would be set to the explicitly-disabled state. With this change, the preference is left in an onboarding state and Chrome will check again the next time Chrome is started. BUG= 695184 Review-Url: https://codereview.chromium.org/2704343005 Cr-Commit-Position: refs/heads/master@{#452571} [modify] https://crrev.com/0e3b410bacaa28cde0c2be4c2eba96451c6ca72a/ios/chrome/browser/physical_web/start_physical_web_discovery.mm
,
Feb 27 2017
Requesting to merge to M57 (see https://bugs.chromium.org/p/chromium/issues/detail?id=695720#c12)
,
Feb 27 2017
This bug requires manual review: Less than 11 days to go before AppStore submit on M57 Please contact the milestone owner if you have questions. Owners: amineer@(clank), cmasso@(bling), ketakid@(cros), govind@(desktop) For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Feb 28 2017
,
Mar 1 2017
Just wanted to check if this has been merged yet? Matt is this ready to be merged and waiting? Should the status still be Started?
,
Mar 2 2017
Please verify that the CL fix the issue in canary.
,
Mar 2 2017
Yes, it's in M58 Canary. It's not merged to M57 yet, still waiting for Merge-Approval.
,
Mar 2 2017
,
Mar 2 2017
Testing instructions The Physical Web preference will auto-enable at Chrome start when the following conditions are met: * Location Services is enabled * Chrome is authorized to use your location "While Using the App" * Google Search is the default search provider * Chrome is not currently in Incognito mode The auto-enable logic will only run if the PhysicalWebEnabled Finch flag is enabled. The flag is enabled server-side for all Beta users but client-side still defaults to "Disabled". This means the client needs to fetch the current Finch configuration from the server before the auto-enable check can run. For a fresh Chrome install, the Finch config is normally fetched the first time Chrome is started. So, the auto-enable logic will typically not be run until the second time Chrome is started. 0. Reset Chrome's Physical Web preference state. The Physical Web preference starts in a Default state, and the auto-enable check will only be run while the preference is still Default. To get Chrome back into the Default state, uninstall/reinstall the app. 1. Configure Chrome so it is not eligible to auto-enable Physical Web. If you reinstalled the app, Chrome will not be authorized for Location and thus is ineligible to auto-enable Physical Web. Alternately, you can disable Location Services, change the default search provider, or force-quit while on an Incognito tab so Chrome will start up in Incognito mode. 2. Launch Chrome once to fetch Finch config If you haven't launched Chrome yet, launch it once to give it an opportunity to sync the Finch config. Chrome will probably prompt to authorize Location. Don't authorize it! You can verify that Finch has not yet been synced by opening Chrome's Privacy settings. If the Physical Web preference is missing, the Finch config has not been synced. 3. Force-quit Chrome, then re-open Force-quit and reopen to force the new Finch config to take effect. This should be the first time the auto-enable check runs. It should fail because one or more of the auto-enable conditions is not met. Verify that the Physical Web preference is included in Chrome's Privacy settings and is still Off. 4. Configure Chrome so it is eligible to auto-enable Physical Web. Make sure the four auto-enable conditions are met, then relaunch Chrome. 5. Check the Physical Web preference state Old behavior: Previously, if the auto-enable check failed once it would disable the feature and never run again. So, we would expect Physical Web preference to still be Off even though the auto-enable conditions are met. New behavior: The Physical Web preference in Chrome's Privacy settings should now be On. If there are nearby URLs, they should be listed in chrome://physical-web.
,
Mar 2 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/b5bdcfde2530d5802d896df554536acdffe9ac3c commit b5bdcfde2530d5802d896df554536acdffe9ac3c Author: Michal Mocny <mmocny@chromium.org> Date: Thu Mar 02 20:40:41 2017 Extend Physical Web iOS auto-enable behavior beyond first launch. On Chrome start, we check whether the device state permits us to auto-enable the Physical Web feature to perform foreground scanning for nearby Bluetooth LE devices broadcasting URLs. Previously, if the auto-enable conditions were not met, the Physical Web preference would be set to the explicitly-disabled state. With this change, the preference is left in an onboarding state and Chrome will check again the next time Chrome is started. BUG= 695184 Review-Url: https://codereview.chromium.org/2704343005 Cr-Commit-Position: refs/heads/master@{#452571} (cherry picked from commit 0e3b410bacaa28cde0c2be4c2eba96451c6ca72a) Review-Url: https://codereview.chromium.org/2725803007 . Cr-Commit-Position: refs/branch-heads/2987@{#742} Cr-Branched-From: ad51088c0e8776e8dcd963dbe752c4035ba6dab6-refs/heads/master@{#444943} [modify] https://crrev.com/b5bdcfde2530d5802d896df554536acdffe9ac3c/ios/chrome/browser/physical_web/start_physical_web_discovery.mm
,
Mar 2 2017
,
Mar 2 2017
Thanks for the details! Vinutha, can you please verify this on M57 once the next M57 build is out?
,
Mar 3 2017
Verified on 57.0.2987.91dev on iPhone7+ iOS 10.1.1 1. Location Services is enabled.Chrome is authorized to use your location "While Using the App”.Google Search is the default search provider.Chrome is not currently in Incognito mode. Clean Install app.Go to Chrome://flags.Enable PW.Force quit app.Relaunch app, go to Menu-Settings->Privacy.PW is ON. 2. Location Services is disabled.Google Search is the default search provider.Chrome is not currently in Incognito mode. Clean Install app.Go to Chrome://flags.Enable PW.Force quit app.Relaunch app, go to Menu-Settings->Privacy.PW is OFF. 3. Location Services is disabled.Google Search is the default search provider.Chrome is not currently in Incognito mode. Clean Install app.Go to Chrome://flags.Enable PW.Force quit app.Relaunch app, go to Menu-Settings->Privacy.PW is OFF.Now to to google.com and and enable location services.Go to Menu-Settings->Privacy.PW is ON 4. Location Services is enabled.Google Search is the default search provider.Chrome is not currently in Incognito mode. Clean Install app.Go to Menu->Settings->Search Engine->Check yahoo! .Go to Chrome://flags.Enable PW.Force quit app.Relaunch app, go to Menu-Settings->Privacy.PW is ON.Go back to iOS settings and disable location services.Force quit app.Relaunch app, go to Menu-Settings->Privacy.PW is OFF. 5.Location Services is enabled.Chrome is authorized to use your location "While Using the App”.Google Search is the default search provider.Go to chrome://flags in incognito mode.Enable PW.Force quit app.Relaunch app, go to Menu-Settings->Privacy.PW is ON.
,
Mar 3 2017
Thank you. Regarding (4) from #15, I think if you set yahoo.com as default search engine (DSE) before turning on the PW flag, then PW would not have turned itself on.
,
Mar 3 2017
As per #16 verified that scenario. https://drive.google.com/open?id=0B6GVWQnhaMClczc4NkQzMlVnSkU
,
Mar 3 2017
Hmm, that is not expected. Thank you for checking so quickly. I wonder if Chrome flag was already enabled in the default state. We will double check!
,
Mar 3 2017
I investigated two cases: Physical Web is auto-enabled even though user is in Incognito mode. Physical Web is auto-enabled with Yahoo.com as DSE. In both cases it seems the feature is not actually being auto-enabled. We are rendering the preference toggle as "On" if Chrome is authorized to use Location even when the feature is still in the Default state. As a more reliable way to distinguish between Default and Enabled in M57, make sure there are Physical Web beacons nearby and navigate to chrome://physical-web. If it's enabled, you should see URLs listed in the WebUI. I filed a new bug, thanks for helping to catch this! https://bugs.chromium.org/p/chromium/issues/detail?id=698392 |
||||||||||
►
Sign in to add a comment |
||||||||||
Comment 1 by mmo...@chromium.org
, Feb 22 2017