When I run npx react-native run androidin the root project folder for my React Native app, I get the following error:
> Task :app:processDebugMainManifest FAILED
11 actionable tasks: 2 executed, 9 up-to-date
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:processDebugMainManifest'.
> Unable to make field private final java.lang.String java.io.File.path accessible: module java.base does not "opens java.io" to unnamed module @11bf9770
I used /usr/libexec/java_home from here (Where is Java Installed on Mac OS X?) to see where Java is located and have set export JAVA_HOME=`/Library/Java/JavaVirtualMachines/jdk-17.0.1.jdk/Contents/Homein my .zshrc file.
I don't know how else to solve this problem, and I would appreciate any help!
Note: I'm a new dev so I'm still fairly new to fixing config errors in the terminal. Thanks!