Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: Browser plugin does not trigger browserFinished event correctly for Android #3896

Closed
fohlin opened this issue Dec 3, 2020 · 2 comments

Comments

@fohlin
Copy link

fohlin commented Dec 3, 2020

Bug Report

Capacitor Version

💊   Capacitor Doctor  💊

Latest Dependencies:

  @capacitor/cli: 2.4.4
  @capacitor/core: 2.4.4
  @capacitor/android: 2.4.4
  @capacitor/electron: 2.4.4
  @capacitor/ios: 2.4.4

Installed Dependencies:

  @capacitor/cli 2.4.4
  @capacitor/core 2.4.4
  @capacitor/ios 2.4.4
  @capacitor/android 2.4.4
  @capacitor/electron not installed

[success] Android looking great! 👌
  Found 0 Capacitor plugins for ios:
[success] iOS looking great! 👌

Platform(s)

Android (tested on Emulator API 29)

Current Behavior

For Capacitor 2.x, the Browser plugin should trigger the browserFinished event as the in-app browser is dismissed. On Android it does not. Instead, the app needs to become inactive and then resumed again. Only then does the browserFinished event listeners get called.

Expected Behavior

iOS displays the expected behavior: browserFinished event listeners get called immediately.

This video expected behavior (iOS) vs. buggy behavior (Android).

Code Reproduction

A small project reproducing this issue can be found at @fohlin/cap-browser-events-repro.

Other Technical Details

npm --version output: 6.14.8

node --version output: v14.15.0

pod --version output (iOS issues only):

Additional Context

Possibly related to: #2332


I realize that development is focus on Capacitor v3, but it would be extremely appreciated if someone has an idea for a fix for this. 🙏

@jcesarmobile
Copy link
Member

I can't reproduce.
Tested on real devices:
Android 5.0.1
Android 9
Android 11
Emulators:
SDK 25
SDK 29
SDK 30

could be a bug on the emulator

@ionitron-bot
Copy link

ionitron-bot bot commented Nov 11, 2022

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Capacitor, please create a new issue and ensure the template is fully filled out.

@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Nov 11, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants