I'm using the url_launcher package in my flutter application. Testing on debug mode works, and so does release mode. However, when I update my app on the play store, it doesn't work. I have also tried different launch modes.
I have the following queries set up in my AndroidManifest.xml
<queries>
<intent>
<action android:name="android.intent.action.PROCESS_TEXT" />
<data android:mimeType="text/plain" />
</intent>
<intent>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="https" />
</intent>
<intent>
<action android:name="android.support.customtabs.action.CustomTabsService" />
</intent>
</queries>
I've come across similar issues already and tried almost all of them to no avail. I've also updated my data privacy security form to include that we do collect Installed Apps under App Activity. I've also tried out most of the android package(app) visibily solutions I've come across including adding the QUERY_ALL_PACKAGES
app permission in my manifest. What I haven't tried yet is adding the specific packages we want to discover(in this case browsers). I don't want to result to this since android already supports discovery via intents.
I'm now wondering if the problem is with some questionnaire or data privacy form that we filled on the play store.
Edit: I also have firebase crashlytics set up and it doesn't report any Uncaught exceptions or ANRs
I'm using the url_launcher package in my flutter application. Testing on debug mode works, and so does release mode. However, when I update my app on the play store, it doesn't work. I have also tried different launch modes.
I have the following queries set up in my AndroidManifest.xml
<queries>
<intent>
<action android:name="android.intent.action.PROCESS_TEXT" />
<data android:mimeType="text/plain" />
</intent>
<intent>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="https" />
</intent>
<intent>
<action android:name="android.support.customtabs.action.CustomTabsService" />
</intent>
</queries>
I've come across similar issues already and tried almost all of them to no avail. I've also updated my data privacy security form to include that we do collect Installed Apps under App Activity. I've also tried out most of the android package(app) visibily solutions I've come across including adding the QUERY_ALL_PACKAGES
app permission in my manifest. What I haven't tried yet is adding the specific packages we want to discover(in this case browsers). I don't want to result to this since android already supports discovery via intents.
I'm now wondering if the problem is with some questionnaire or data privacy form that we filled on the play store.
Edit: I also have firebase crashlytics set up and it doesn't report any Uncaught exceptions or ANRs
Share Improve this question edited Mar 12 at 9:20 Newton Nthiga asked Mar 12 at 8:59 Newton NthigaNewton Nthiga 457 bronze badges 3 |2 Answers
Reset to default 0Try to explicitly launch the browser in external mode:
await launchUrl(url, mode: LaunchMode.externalApplication);
Figured it out, this was just a silly developer mistake. I had a web link set up in my AndroidManifest similar to the url I was trying to open from inside the app, so basically every time I try to launch the URL nothing would happen. Opening the URL from outside the app would just launch the app but since the app is already open nothing happens if you're not handling web links/deep links.
Reason why it didn't work on app downloaded from play store is because I had verified the weblink domain and allowed share credentials. The app therefore came already set up to open such links by default. When installing a debug/release apk you need to set the app as the default to open such links instead of a browser.
launchUrl
returns true but nothing happens. Try catch, doesn't catch any errors. – Newton Nthiga Commented Mar 12 at 10:53canLaunchUrl
, notlaunchUrl
. If you don't show your code, and focus your question on things that are only relevant tocanLaunchUrl
, it's going to be difficult for anyone to understand the question if it wasn't intended to be aboutcanLaunchUrl
. – sman Commented Mar 13 at 2:50