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

Issue 888815 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Sep 26
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 1
Type: Bug


Participants' hotlists:
Better-Together-Launch-Blockers


Sign in to add a comment

Do not scan for Tether hosts on lock screen (with MultiDevice flags)

Project Member Reported by hansberry@chromium.org, Sep 25

Issue description

In line with  crbug.com/881820 , Tether should not scan when not necessary. Due to async behavior, Chromebooks briefly have no network connectivity on wake (takes about ~1 second to connect to their network), prompting a Tether scan (which is unnecessary). 

This can be fixed by observing screen lock state in HostScanScheduler and preventing scans when the screen is locked.

Note: unlike  crbug.com/881820 , this change does not need to be merged into M70 or M69. The fix to  crbug.com/881820  still ensures that if kMultiDeviceApi is not enabled, HostScanScheduler will wait a certain amount of time before trying to scan -- by that time, the Chromebook finds a network connection, and cancels the Tether scan (I've manually confirmed this).
 
Summary: Do not scan for Tether hosts on lock screen (with MultiDevice flags) (was: Do not scan for Tether hosts on lock screen)
Further clarification: as-is, Tether only scans on the lock screen if the kMultiDeviceApi flag is on. Therefore this is only an issue in M71.
Further note for posterity: this was a behavior regression from the old flow, i.e., when implementing the new flow, scanning on the lock screen still should have been disabled.
Would it be better to delay the scan for a few seconds to wait until the device has had time to obtain an Internet connection? That way, the user could have a potential tether connection ready and waiting once the device is unlocked.
We can revisit whether to scan or not on the lock screen post-launch, but for now the spec is that tether does not scan on the lock screen at all.

As a side note, I'd really like to see metrics about median time-to-tether-availability to justify whether scanning on the lock screen is even necessary.
Project Member

Comment 5 by bugdroid1@chromium.org, Sep 25

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b3ef4d796d7d45f5f27e1bc6cb328a120afb57f7

commit b3ef4d796d7d45f5f27e1bc6cb328a120afb57f7
Author: Ryan Hansberry <hansberry@chromium.org>
Date: Tue Sep 25 20:05:36 2018

Tether: never attempt host scans when screen is locked

Tether originally initiated host scans from the lock screen,
in order to provide a list of hosts once the user unlocked the
device. This was changed when it was discovered that Bluetooth issues
meant Tether and SmartLock could not scan simultaneously. It was
assumed that this restriction would no longer apply one the new
MultiDevice APIs were available, but we now never want to allow host
scans on the lock screen; this CL implements that logic.

Bug:  888815 
Change-Id: I392e61e8ad404372df42cf2240c65cac81651608
Reviewed-on: https://chromium-review.googlesource.com/1242214
Reviewed-by: Kyle Horimoto <khorimoto@chromium.org>
Commit-Queue: Ryan Hansberry <hansberry@chromium.org>
Cr-Commit-Position: refs/heads/master@{#594072}
[modify] https://crrev.com/b3ef4d796d7d45f5f27e1bc6cb328a120afb57f7/chromeos/components/tether/host_scan_scheduler_impl.cc
[modify] https://crrev.com/b3ef4d796d7d45f5f27e1bc6cb328a120afb57f7/chromeos/components/tether/host_scan_scheduler_impl_unittest.cc

Reaching out to the TPM to ensure this makes M71 dev channel build cut.
Cc: geohsu@chromium.org
Labels: -Pri-2 Merge-Request-70 Pri-1
We also need to merge this into M70 -- requesting merge.
(Bumping up to priority 1 because this causes a crash on wake after suspension)
Project Member

Comment 9 by sheriffbot@chromium.org, Sep 26

Labels: -Merge-Request-70 Merge-Review-70 Hotlist-Merge-Review
This bug requires manual review: M70 has already been promoted to the beta branch, so this requires manual review
Please contact the milestone owner if you have questions.
Owners: benmason@(Android), kariahda@(iOS), geohsu@(ChromeOS), abdulsyed@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: -Merge-Review-70 Merge-Approved-70
Labels: -Merge-Approved-70 Merge-Merged-70-3538
The following revision refers to this bug: 
https://chromium.googlesource.com/chromium/src.git/+/a8f1c49ac80bf695662d1ff42718c0eba88c20f1

Commit: a8f1c49ac80bf695662d1ff42718c0eba88c20f1
Author: hansberry@chromium.org
Commiter: hansberry@chromium.org
Date: 2018-09-26 20:39:03 +0000 UTC

Tether: never attempt host scans when screen is locked

Tether originally initiated host scans from the lock screen,
in order to provide a list of hosts once the user unlocked the
device. This was changed when it was discovered that Bluetooth issues
meant Tether and SmartLock could not scan simultaneously. It was
assumed that this restriction would no longer apply one the new
MultiDevice APIs were available, but we now never want to allow host
scans on the lock screen; this CL implements that logic.

Bug:  888815 
Change-Id: I392e61e8ad404372df42cf2240c65cac81651608
Reviewed-on: https://chromium-review.googlesource.com/1242214
Reviewed-by: Kyle Horimoto <khorimoto@chromium.org>
Commit-Queue: Ryan Hansberry <hansberry@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#594072}(cherry picked from commit b3ef4d796d7d45f5f27e1bc6cb328a120afb57f7)
Reviewed-on: https://chromium-review.googlesource.com/1246949
Reviewed-by: Ryan Hansberry <hansberry@chromium.org>
Cr-Commit-Position: refs/branch-heads/3538@{#689}
Cr-Branched-From: 79f7c91a2b2a2932cd447fa6f865cb6662fa8fa6-refs/heads/master@{#587811}
Project Member

Comment 12 by bugdroid1@chromium.org, Sep 26

Labels: merge-merged-3538
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a8f1c49ac80bf695662d1ff42718c0eba88c20f1

commit a8f1c49ac80bf695662d1ff42718c0eba88c20f1
Author: Ryan Hansberry <hansberry@chromium.org>
Date: Wed Sep 26 20:39:03 2018

Tether: never attempt host scans when screen is locked

Tether originally initiated host scans from the lock screen,
in order to provide a list of hosts once the user unlocked the
device. This was changed when it was discovered that Bluetooth issues
meant Tether and SmartLock could not scan simultaneously. It was
assumed that this restriction would no longer apply one the new
MultiDevice APIs were available, but we now never want to allow host
scans on the lock screen; this CL implements that logic.

Bug:  888815 
Change-Id: I392e61e8ad404372df42cf2240c65cac81651608
Reviewed-on: https://chromium-review.googlesource.com/1242214
Reviewed-by: Kyle Horimoto <khorimoto@chromium.org>
Commit-Queue: Ryan Hansberry <hansberry@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#594072}(cherry picked from commit b3ef4d796d7d45f5f27e1bc6cb328a120afb57f7)
Reviewed-on: https://chromium-review.googlesource.com/1246949
Reviewed-by: Ryan Hansberry <hansberry@chromium.org>
Cr-Commit-Position: refs/branch-heads/3538@{#689}
Cr-Branched-From: 79f7c91a2b2a2932cd447fa6f865cb6662fa8fa6-refs/heads/master@{#587811}
[modify] https://crrev.com/a8f1c49ac80bf695662d1ff42718c0eba88c20f1/chromeos/components/tether/host_scan_scheduler_impl.cc
[modify] https://crrev.com/a8f1c49ac80bf695662d1ff42718c0eba88c20f1/chromeos/components/tether/host_scan_scheduler_impl_unittest.cc

Status: Fixed (was: Assigned)

Sign in to add a comment