zulip / zulip-mobile

Zulip mobile apps for Android and iOS.
https://zulip.com/apps/
Apache License 2.0
1.27k stars 643 forks source link

"No browser found" on web login or opening link, when no Chrome app #5466

Open daald opened 2 years ago

daald commented 2 years ago

On my Samsung Galaxy S10 I get a "no browser found" error when trying to login (server is chat.sac-uto.ch).

Phone is up-to-date: Android 12 patchlevel May 1, 2022

Packages installed: from the releases page: v27.189 https://github.com/zulip/zulip-mobile/releases/download/v27.189/app-arm64-v8a-release.apk

daald commented 2 years ago

solved. I've disabled chrome browser

gnprice commented 2 years ago

Thanks @daald for the report! Glad it's now working for you.

Can you say a bit more about how you disabled Chrome? We've heard about an issue like this once before, and would love to better understand what's going on -- both to help the next person who sees it, and ideally so we can fix the problem entirely.

daald commented 2 years ago

Sure.

  1. Long-press to Chrome in the launcher
  2. press the (i)
  3. on the bottom, there is a "disable" button, near "force stop" and "open"

This is to disable apps which are included in the firmware image, like youtube or spotify. if an app was installed through apk or a store, there is an "uninstall" button instead.

I saw in the code there is another option for opening a browser window before failing. But didn't find out which other application could be needed for this

zer0def commented 1 year ago

To expand on observed behavior:

gnprice commented 5 months ago

Thanks @daald for those details, and @zer0def for the debugging!

Looking at the code of ours that's at those links, the logic definitely seems dubious — particularly in how it checks for com.android.chrome by name before launching a CustomTabsIntent, which isn't specific to Chrome. I'm not seeing how that bug would lead to a situation where disabling Chrome works around the problem, but I'm glad it did for @daald.

Because this app is now in maintenance mode as we're focused on building the new Zulip mobile app in Flutter, this is an issue I don't expect us to go back and fix for the legacy app. In the new app, fortunately, this functionality is provided by a package from Flutter upstream, and I think its logic is more solid than this. So I'd expect this sort of issue shouldn't arise in the new app — and if it does, I'll definitely be interested in getting to the bottom of it there.

daald commented 5 months ago

@gnprice No, it was the other way round. I had chrome disabled, that's why Zulip failed. After re-enabling, it worked. But there were 2 other browsers installed, so there was no reason to fail, just because Chrome was not there. The above instructions where for reproducing, not for solving the issue...

gnprice commented 5 months ago

Ah excellent, thanks for clarifying. All makes sense then. (Still a bug, but it now makes sense how the bug caused the pattern of behavior you saw.)

The reason I'd thought that disabling Chrome was the workaround was this part:

solved. I've disabled chrome browser

gnprice commented 5 months ago

I've edited the title a bit to reflect the debugging above, and also the alternate symptom reported in #5795 that I believe is caused by this same issue.