peterferguson / react-native-passkeys

56 stars 6 forks source link

Androd: expo 50 build error #8

Closed adrianofoschi closed 4 months ago

adrianofoschi commented 4 months ago

I just created an application with expo 50 and I have this error.

I inserted compileSdkVersion 34 into my app.json My installed jdk version is 17

> Task :react-native-passkeys:compileDebugKotlin FAILED

> Task :expo-constants:compileDebugKotlin
w: file:///home/adriano/koi/node_modules/expo-constants/android/src/main/java/expo/modules/constants/ConstantsService.kt:127:14 'versionCode: Int' is deprecated. Deprecated in Java

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':react-native-passkeys:compileDebugKotlin'.
> 'compileDebugJavaWithJavac' task (current target is 17) and 'compileDebugKotlin' task (current target is 11) jvm target compatibility should be set to the same Java version.
  Consider using JVM toolchain: https://kotl.in/gradle/jvm/toolchain

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.
> Get more help at https://help.gradle.org.

Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

For more on this, please refer to https://docs.gradle.org/8.3/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.

BUILD FAILED in 4m 52s
143 actionable tasks: 90 executed, 48 from cache, 5 up-to-date
Error: /home/adriano/koi/android/gradlew exited with non-zero code: 1
Error: /home/adriano/koi/android/gradlew exited with non-zero code: 1
    at ChildProcess.completionListener (/home/adriano/koi/node_modules/@expo/spawn-async/build/spawnAsync.js:52:23)
    at Object.onceWrapper (node:events:632:26)
    at ChildProcess.emit (node:events:517:28)
    at maybeClose (node:internal/child_process:1098:16)
    at ChildProcess._handle.onexit (node:internal/child_process:303:5)
    ...
    at Object.spawnAsync [as default] (/home/adriano/koi/node_modules/@expo/spawn-async/build/spawnAsync.js:17:21)
    at spawnGradleAsync (/home/adriano/koi/node_modules/@expo/cli/build/src/start/platforms/android/gradle.js:72:46)
    at Object.assembleAsync (/home/adriano/koi/node_modules/@expo/cli/build/src/start/platforms/android/gradle.js:52:18)
    at runAndroidAsync (/home/adriano/koi/node_modules/@expo/cli/build/src/run/android/runAndroidAsync.js:36:24)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
adrianofoschi commented 4 months ago

I checked this PR works https://github.com/peterferguson/react-native-passkeys/pull/6