mediasoup-client – Error Detecting Device with Chrome Extension

Hello Team,

I often use this Chrome extension for testing the UI on different devices:
Mobile simulator - responsive testing tool.

Since the recent browser detection update, I get an error when the extension is enabled: Maybe it not detect the handlerName for the device?

Previously, everything worked fine.

Could you please take a look at this?

Thank you,
Miroslav

This is fixed in 3.16.4 in this commit: Be ready for nasty browser extensions that define their custom `navig… · versatica/mediasoup-client@707c518 · GitHub

Please, next time, if it looks like a bug (despite it was a bug in that Chrome extension) report an issue in GitHub.

1 Like

Yes, I confirm it’s fixed now. Thank you! And sure, I’ll make sure to report any similar issues on GitHub next time. Keep up the good work!

Mh, Works fine on desktop, but seems not to work on

tablet

mobile

Got devices not supported

Any chance you could work around this? I’ve never seen this issue before, and as I mentioned, this extension is super helpful for testing Mediasoup UI or MiroTalk-SFU in my case on different devices.

Thank you! :folded_hands:

Those devices are emulating old versions of iOS/Safari so indeed they are not supported anymore. Support for old Chromoum and Safari based browsers were removed in a recent PR in mediasoup-client on purpose. I’m sorry but the free devices that that browser extension emulates are too old.

In other words: if you had an iPad PRO 11 with a modern iOS version (rather than the original iOS version when that device was launched back in 2018) then it mediasoup-client would support it.

So if you want to play with that browser extension emulating that iPad you should mangle the global window.userAgent value or pass Safari12 handler to the Device constructor to bypass User-Agent based auto detection.

Ah, got it, so the workaround is to explicitly force the handlerName when creating the device, in order to use the Mobile Simulator extension (for testing purposes only). For example:

const device = await this.mediasoupClient.Device.factory({ handlerName: 'Safari12' }); // or Chrome74, Chrome111, etc.

This bypasses the user-agent–based detection and allows the extension to work again, even though it emulates older iOS/Safari versions.

Thank you!