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
[android][expo-local-authentication] supportedAuthenticationTypesAsync returns wrong type for Pixel 4 #7838
Comments
It looks like the underlying Android library doesn't distinguish between the available authentication type. Does it make more sense to return a generic |
Hi @awinograd! Good catch, that's definitely something we should fix 😄 I'll put it on our list to take a closer look at once we upgrade to Android R. To me, it looks sensible to add a more abstract |
Forgive me if leveraging this thread for this question is a big NO. I have a semi-related question We just updated to SDK37 and need to account for the breaking changes from What will happen when this is called on Thanks!! |
Hi @byCedric,
Are you suggesting this will be fixed only in the next major release? Our Samsung Galaxy S10 has the same issue, so this isn't limited to Pixel 4. |
Hi @vernondegoede! I'm sorry if my wording felt like we were delaying this, that's not the case. We are exploring some options at the moment to implement the best fix, preferably without breaking changes. Just to clarify, does your S10 not have a fingerprint? Or do you have facial recognition set-up, but it's returning as fingerprint? |
Cool! My S10 does have the ability to use fingerprint, but it's not set up. I do have facial recognition set-up, though. Since facial recognition is not recognized as an available local authentication method, we therefore fall back to passcode. |
Hello guys! 👋 This is definitely something that we need to lean over. I'm generally fine with introducing separate To sum up, I'd be more for just slowly deprecating |
I also wanted to refer to @bayoremit question:
|
Thanks for the info, @tsapeta. I think you're right that I do think there's value in knowing what type of sensor is available on the device to adapt the UI/text accordingly, but if Android APIs don't allow for that then is sounds like we're out of luck! |
Thanks @tsapeta and others for taking a deep dive into this. As addition I also want to mention a couple of things:
|
https://handstandsam.com/2020/01/03/android-biometrics-ux-guide-user-messaging/ This article seems to suggest it is possible to determine the sensors on Android using packageManager.hasFeature(PackageManager.FEATURE_FINGERPRINT) I think having these values for android under supportedAuthenticationTypesAsync would be much better than a generic "biometric" response. |
…ith package manager (#8431) # Why See #8364 # How See #8364 # Test Plan See #7838 or https://snack.expo.io/@ouihealth/a78fc1
I believe this issue is fully addressed by #8431. I'm running expo-local-auth 9.2.0 and types are returning as expected on android now |
🐛 Bug Report
The Pixel 4 has facial recognition, but no fingerprint sensor.
LocalAuthentication.supportedAuthenticationTypesAsync
returns as if the Pixel 4 had a fingerprint sensor but no facial recognition.Environment
Expo CLI 3.17.14 environment info:
System:
OS: macOS 10.15.3
Shell: 5.7.1 - /bin/zsh
Binaries:
Node: 12.14.0 - ~/.nodenv/versions/12.14.0/bin/node
Yarn: 1.12.1 - ~/.yarn/bin/yarn
npm: 6.13.4 - ~/.nodenv/versions/12.14.0/bin/npm
IDEs:
Android Studio: 3.5 AI-191.8026.42.35.6010548
Xcode: 11.3.1/11C504 - /usr/bin/xcodebuild
npmPackages:
expo: ^37.0.0 => 37.0.3
react: 16.9.0 => 16.9.0
react-native: https://github.com/expo/react-native/archive/sdk-37.0.0.tar.gz => 0.61.4
Targeting Pixel 4 (android) standalone & expo client
Steps to Reproduce
Expected Behavior
Should render
{ supportedTypes: [2] }
to the screenActual Behavior
Renders
{ supportedTypes: [1] }
to the screenReproducible Demo
https://snack.expo.io/@ouihealth/a78fc1
The text was updated successfully, but these errors were encountered: