question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

react-native-keychain version 3.1.1 compileDebugJavaWithJavac FAILED

See original GitHub issue

When I building projet, throw this error. How can solve this?

> Task :react-native-keychain:compileDebugJavaWithJavac FAILED
node_modules/react-native-keychain/android/src/main/java/com/oblador/keychain/cipherSt
orage/CipherStorageKeystoreAESCBC.java:28: error: cannot find symbol
import android.security.keystore.StrongBoxUnavailableException;
                                ^
  symbol:   class StrongBoxUnavailableException
  location: package android.security.keystore
node_modules/react-native-keychain/android/src/main/java/com/oblador/keychain/cipherStorage/CipherStorageKeystoreAESCBC.java:266: error: cannot find symbol
    @TargetApi(Build.VERSION_CODES.P)
                                  ^
  symbol:   variable P
  location: class VERSION_CODES
node_modules/react-native-keychain/android/src/main/java/com/oblador/keychain/cipherStorage/CipherStorageKeystoreAESCBC.java:270: error: cannot find symbol
        if (Build.VERSION.SDK_INT < Build.VERSION_CODES.P) {
                                                       ^
  symbol:   variable P
  location: class VERSION_CODES
node_modules/react-native-keychain/android/src/main/java/com/oblador/keychain/cipherStorage/CipherStorageKeystoreAESCBC.java:274: error: cannot find symbol
            return generateKey(getKeyGenSpecBuilder(service).setIsStrongBoxBacked(true).build());
                                                            ^
  symbol:   method setIsStrongBoxBacked(boolean)
  location: class Builder
node_modules/react-native-keychain/android/src/main/java/com/oblador/keychain/cipherStorage/CipherStorageKeystoreAESCBC.java:275: error: cannot find symbol
        } catch (StrongBoxUnavailableException e) {
                 ^
  symbol:   class StrongBoxUnavailableException
  location: class CipherStorageKeystoreAESCBC
5 errors


System: OS: macOS 10.14.1 Shell: 3.2.57 - /bin/bash Binaries: Yarn: 1.13.0 - /usr/local/bin/yarn npmPackages: react: 16.6.3 => 16.6.3 react-native: 0.57.8 => 0.57.8

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:2
  • Comments:16

github_iconTop GitHub Comments

20reactions
mandrigincommented, Feb 14, 2019

@vdpdev @burhanyilmaz what version of Android SDK do you use? build.gradle of your app (android/app/build.gradle)? Does changing it compileSdkVersion 28 help?

13reactions
ksetrincommented, Jun 16, 2020

I had this config but the project was cannot be compiled

ext {
        buildToolsVersion = "28.0.3"
        minSdkVersion = 16
        compileSdkVersion = 28
        targetSdkVersion = 28
    }

After I changed to this config my project have been compiled

    ext {
        buildToolsVersion = "29.0.3"
        minSdkVersion = 16
        compileSdkVersion = 29
        targetSdkVersion = 29
    }

file android/build.gradle

Read more comments on GitHub >

github_iconTop Results From Across the Web

Compilation failed (android) after installation ... - Stack Overflow
Bumped up the SDK version from 28 to 29 in build.gradle seems working. Here is the file after change:
Read more >
react-native-keychain - Bountysource
Build fails every time. I can't set my compile version to 29 because reanimated (and other libraries) need some R reference that 29...
Read more >
app:compiledebugjavawithjavac'., execution failed for task '
task ':react-native-keychain:compiledebugjavawithjavac failed. Starting a Gradle Daemon, 1 busy Daemon could not be reused, use --status for details > Task ...
Read more >
react-native-keychain - npm
Keychain Access for React Native. Latest version: 8.1.1, last published: 5 months ago. Start using react-native-keychain in your project by ...
Read more >
execution failed for task ':amazon-cognito-identity-js ... - You.com
Code Snippet yarn run v1.22.4 $ react-native run-android info Running jetifier to ... Task :amazon-cognito-identity-js:compileDebugJavaWithJavac FAILED.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found