Using a Samsung S10e on Android 12, I was able in the past to open our React Native application (https://github.com/pass-culture/pass-culture-app-native) through Universal Links.
We removed first all apps, all other browsers than chrome (such as samsung browswer), and then we did a factory reset using this menu:
It still can't open the app through universal link. All our other test devices from our team are able to open those universal links.
I tested from the email app (Gmail), slack, and so on, nothing work.
This is our assetlinks.json
:
https://app.passculture.app/.well-known/assetlinks.json
This is a video demonstrating the bug:
We recently upgrading the device from Android 11 to Android 12, and it seems Google modified the behavior of applinks:
App links and our configuration seems to be OK.
This is our assetlinks : https://app.testing.passculture.team/.well-known/assetlinks.json
This is the error:
adb shell pm get-app-links app.passculture.testing
app.passculture.testing:
ID: 7b7458c4-f595-4840-839c-a6c1089b7b12
Signatures: [F2:59:8C:3F:07:B3:8E:6D:D0:20:A8:1B:A1:02:7B:82:41:53:88:D8:84:0E:CB:22:87:CC:CD:12:F0:8E:32:7F]
Domain verification state:
app.testing.passculture.team: legacy_failure
Consequence are that adb shell am start -a android.intent.action.VIEW \ -c android.intent.category.BROWSABLE \ -d "https://app.testing.passculture.team"
only open the web instead of the native application.
Since Android 12 changed the applinks behavior, this is how we are testing but since it stays in legacy_failure
, we still open the web :
This is related ressources we have found:
- https://doordash.engineering/2022/01/25/your-deep-links-might-be-broken-web-intents-and-android-12/
- https://developer.android.com/training/app-links/verify-site-associations#auto-verification
- App Link not opening in Android 12 by default. Possible SHA256 issue
- Android App Links manual verification not working
- https://zarah.dev/2022/02/08/android12-deeplinks.html
Does anybody can tell what is going on with Android 12 and applinks and how it can be fixed ?
There was a change in the policy for universal link from Android 12 (sdk 31), Google requires to use Android App Link, if you dont use it the app doesnt open. This article could help you: https://doordash.engineering/2022/01/25/your-deep-links-might-be-broken-web-intents-and-android-12/