status-im / status-mobile

a free (libre) open source, mobile OS for Ethereum
https://status.app
Mozilla Public License 2.0
3.85k stars 982 forks source link

Can't enable Face ID after disabling it via system settings #20149

Open churik opened 1 month ago

churik commented 1 month ago

Bug Report

Description

After enabling Face ID in the app settings it is availble in system app permissions, and if you disable it there, it is not possible to enable them again via the app.

Steps to reproduce

  1. App > Settings > Password > Enable Face ID
  2. Go to system settings > Status > Disable Face ID
  3. Tey to enable it again via App > Settings > Password > Enable Face ID

Expected behavior

Face ID is available in Settings > Password > Enable Face ID Can enable it again

Actual behavior

Touch ID is shown instead of Face ID Error at attepmt to enable it

https://github.com/status-im/status-mobile/assets/4557972/a8e6f7d7-894a-4d1b-882d-b565eb08e202

Additional Information

yqrashawn commented 1 week ago

PR #20227 only fixes the error message Touch ID is still showing when face ID is not available

Also, there's issue https://github.com/status-im/status-mobile/issues/20435 for android and I think our app do not support face ID on android devices that do have face ID access for third-party apps

Face ID is available in Settings > Password > Enable Face ID

I'll try fix this in another PR

yqrashawn commented 1 week ago

react native biometrics can't detect the sensor type when permission is turned off and our code will fallback to Touch ID (even on Android)

Touch ID is shown instead of Face ID

I see two options here

What do you think? @churik @cammellos @ilmotta

(condp = biometric-type ;; null when no permission
    constants/biometrics-type-android (i18n/label :t/biometric-fingerprint)
    constants/biometrics-type-face-id (i18n/label :t/biometric-faceid)
    (i18n/label :t/biometric-touchid))
churik commented 1 week ago

I'd prefer something more general word for the fallback, and it seems the simplest solution, right?

ilmotta commented 1 week ago

I'd prefer something more general word for the fallback, and it seems the simplest solution, right?

I agree with @churik that seems reasonable. If we use a generic "Biometric" word, then the icon should ideally change as well because it's neither fingerprint nor touch ID. A minor detail of course.

@yqrashawn, it would be good to align such decisions quickly with a designer because we want to avoid a situation where the implementation was well thought out on the implementation side, but looks like a UI bug on the outside (from designer's perspective). Another benefit is if we tell them, they get a chance to update Figma, thus helping reduce Figma/code drifting.

clauxx commented 6 days ago

Can enable it again

@churik This expected behaviour might be (very) difficult to add, since the app doesn't have the permission to access biometrics altogether and can't be enabled, so I guess we need to update the issue to "fixing the biometrics fallback information" or smth.

yqrashawn commented 2 days ago

use "Biometric" as fallback and use fingerprint icon https://discord.com/channels/1210237582470807632/1217173586054480035/1253358826875261040