hello guys i have 2 react-native-cli projects in my pc
the first project was created using react-native init myproject and it is working fine when i run it on my android phone through usb cable
i dont get any errors on react-native run-android i have installed all the necessary things like jdk,sdk, etc so it is working fine.
now the 2nd project which i have cloned from github repo and after that i do npm install and after getting node_modules etc i try to run it react-native run-android the same way but i get errors running this project
here is errors list
**FAILURE: Build failed with an exception.
BUG! exception in phase 'semantic analysis' in source unit 'BuildScript' Unsupported class file major version 62
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
BUILD FAILED in 1s
error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup. Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081**
BUILD FAILED in 1s
at makeError (D:\Soft Projects\pt project\pt_mobile_app\node_modules\execa\index.js:174:9)
at D:\Soft Projects\pt project\pt_mobile_app\node_modules\execa\index.js:278:16
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async runOnAllDevices (D:\Soft Projects\pt project\pt_mobile_app\node_modules\@react-native-community\cli-platform-android\build\commands\runAndroid\runOnAllDevices.js:109:5)
at async Command.handleAction (D:\Soft Projects\pt project\pt_mobile_app\node_modules\react-native\node_modules\@react-native-community\cli\build\index.js:192:9)
info Run CLI with --verbose flag for more details.