Skip to main content

Troubleshooting

1. SDK Already Initialized Error

  • Problem: IllegalStateException: SDK is already is initialized
  • Solution: Call reset() before re-initializing, or ensure initialization only happens once in your Application class.
if (MetricFingerprint.isInitialized()) {
MetricFingerprint.reset()
}
MetricFingerprint.init(...)

2. Activity Not Found Error

  • Problem: ActivityNotFoundException when launching SDK.
  • Solution: Ensure companyName is not blank, color is a valid hex color (e.g., #f7cd46), logo URL is not blank (if using Logo.Url)

3. Theme Validation Error

  • Problem: IllegalArgumentException when creating FingerprintTheme.
  • Solution: Ensure the SDK is properly initialized and the Activity is merged into your manifest. The Activity is automatically merged - you don't need to add it manually.

4. Token is Empty

  • Problem: SDK launches but shows error about missing token.
  • Solution: Ensure you're passing a valid token in FingerprintAuthRequest. The token should be generated from your backend API before launching the SDK.

5. Result Not Received

  • Problem: Activity Result callback not being called.
  • Solution: Ensure you're using registerForActivityResult correctly and the Activity is not being destroyed before the result is returned.

6. Permissions Not Requested

  • Problem: SDK doesn't request camera/USB permissions.
  • Solution: The SDK automatically requests permissions. Ensure you've added the required permissions to your AndroidManifest.xml.

7. Logo Not Loading

  • Problem: Logo from URL doesn't appear.
  • Solution: Check that the URL is accessible; Ensure your app has internet permission; For drawable logos, ensure the resource exists

8. No Logs Appearing

  • Problem: Can't see SDK logs in logcat.
  • Solution:
    • Check if logging is enabled: By default, SDK logging is automatically disabled in release builds and enabled in debug builds.
    • Enable logging manually (for debugging release builds):
      • MetricFingerprintCore.setLoggingEnabled(true)
      • Filter logs by tag "MetricFingerprint":
Key log prefixes: - [Activity] - FingerprintAuthActivity - [DeviceManager] - IBScanDeviceManager - [CaptureManager] - FingerprintCaptureManager - [IBScanCapture] - IBScanCaptureManager - [ScanScreen] - FingerprintScanningScreen - [ProcessingScreen] - ProcessingScreen