Open Bug 1986461 Opened 1 year ago Updated 6 months ago

Broken webcam selection workflow in teams.microsoft.com and teams.live.com

Categories

(Web Compatibility :: Site Reports, defect, P2)

Tracking

(Webcompat Priority:P2, Webcompat Score:5)

Webcompat Priority P2
Webcompat Score 5

People

(Reporter: jgraham, Unassigned)

References

(Blocks 1 open bug, )

Details

(Keywords: webcompat:have-login, webcompat:site-report, Whiteboard: [webcompat:sightline][webcompat:diagnosis:site-bug][webcompat:core])

User Story

platform:windows,mac,linux
impact:annoyance
configuration:common
affects:all
branch:release
diagnosis-team:media
user-impact-score:150

On a device with multiple cameras the workflow to select a non-default camera is somewhat broken.

STR:

  • Click on the camera icon ("Meet Now")
  • Click "Start Meeting"
  • You now get prompted for the camera / microphone. At least the first time I try this only the default camera is provided as an option. If that's the case you can deny access and otherwise you can select the desired non-default device. Either way the next step happens.
  • Once the meeting starts you are again prompted for access to the default camera and microphone devices. In this case only the default is available. Since you don't want to grant access to this, press "Not Now"
  • You are now in the meeting with broken video and audio. But at this point you can select the correct camera and microphone from the app controls. However opening the camera selection dropdown will again produce a prompt asking for access to the default camera (which is selected).
  • At this point, continuing to not allow access to the default device, and selecting the desired device eventually works (if you already granted permission for this device no additional permission prompt is produced, otherwise it is). You do need to both select a working device and again press the camera button to actually enable the camera.
  • Similar story with the microphones.

In Chrome I can pick the (non-default) camera and microphone I want in the first permission prompt and that camera and microphone are automatically used by Teams for the meeting.

Severity: -- → S4
User Story: (updated)
Webcompat Priority: --- → P3
Webcompat Score: --- → 4
Priority: -- → P3
Summary: Broken webcam selection workflow in teams.live.com → Broken webcam selection workflow in teams.microsoft.com and teams.live.com
Blocks: teams
User Story: (updated)
Webcompat Priority: P3 → P2
Webcompat Score: 4 → 5
Priority: P3 → P2

This is a common web developer mistake. The spec shows in example 6 how to

  1. avoid overconstraining on a single device in initial prompts, and
  2. extract deviceIds from the devices the user chose in the permission prompt

Firefox is the only browser that grants permission per-device, which is why you see a prompt for each device chosen. Fix the code to let the user choose their desired device upfront and the other prompts should go away.

We'll forward this information to Teams.

Why it appears to work in Chrome's new picker:

Chrome appears to rearrange the order of devices listed in enumerateDevices() to list the devices the user chose in the prompt first. Why this works for Teams isn't clear, but it might be accidental.

Unfortunately, that's not to spec which says the "system default" device should be listed first, and to fire a devicechange event when that changes (which Chrome doesn't do when it's changed like this from the user selecting a camera in its prompts AFAICT, and would be confusing if it did). IOW, it appears Chrome is effectively letting its user pick which devices are "system default" for that page.

For web developers, instead on relying on this nonstandard behavior, I recommend the approach in comment 2 which should work in all browsers.

We will meet with them on Thursday and will ask about this.

Whiteboard: [webcompat:sightline]

Thanks for reporting folks, I confirm that I can easily reproduce this in Firefox 144. However, 145 and 146 has a chrome-like behavior allowing the browser to select the device. Have there been changes in this area? Is it reproducible using 145+ for you as well?

Flags: needinfo?(jib)

Yes it reproduces for me in both 144 (release) and 146 (nightly). Other than a camera preview added to the Firefox prompt in 143, the selection logic in the prompt remains the same.

To clarify: the problem only manifests when the user picks a different camera device from the one offered in the Firefox permission prompt, and does so from inside that prompt.

Here are the REPRO STEPS I use:

  1. Ensure two cameras are connected
  2. Clear any previous Allowed ✖ or Allowed Temporarily ✖ permissions for camera in the dropdown to the immediate left of the URL bar
  3. Click "Meet Now" in Teams
  4. In the Firefox permission prompt that appears, change the camera offered (A) to the OPPOSITE one (B), and hit Allow
  5. The Teams lobby appears (If a self view does not appear, click the unmute button in the lobby UX)

Expected result:

  • Camera B is rendered in the lobby

Actual result:

  • Firefox prompts for permission to Camera A specifically
  • When allowed, Camera A appears
  • User has to change camera from the web UX instead.

Note Firefox can be inconsistent in which camera it considers the default depending on when devices are plugged in. Just make sure whichever one it suggests you pick the opposite.

Flags: needinfo?(jib)

Thank you very much for the additional information!

In 144 I only see the default camera the permission prompt, while 145/146 allows selecting the camera. Perhaps I might have some configuration in the stable Firefox instance version interfering with this, I'll try again with a clear state.

Whiteboard: [webcompat:sightline] → [webcompat:sightline][webcompat:diagnosis:site-bug]

Need to retest at the next opportunity. Maybe WFM

Whiteboard: [webcompat:sightline][webcompat:diagnosis:site-bug] → [webcompat:sightline][webcompat:diagnosis:site-bug][webcompat:core]
You need to log in before you can comment on or make changes to this bug.