آموزش جاوااسکریپت انجمن ها react native اجرا نشدن react-native run-android

در حال نمایش 15 نوشته (از کل 23)
  • نویسنده
    نوشته‌ها
  • #21873 پاسخ
    mehdi_biniaz
    مشارکت کننده

    سلام
    من مشکل دارم وقتی react-native run-android رو تو cmd میزنم
    و این ارور رو میده
    Starting JS server…
    Building and installing the app on the device (cd android && gradlew.bat installDebug)…
    Support for running Gradle using Java 7 has been deprecated and is scheduled to be removed in Gradle 5.0. Please see https://docs.gradle.org/4.4/userguide/java_plugin.html#sec:java_cross_compilation for more details.

    FAILURE: Build failed with an exception.

    * Where:
    Build file ‘E:\mehdi\react-native-project\mhdc\android\app\build.gradle’ line: 1

    * What went wrong:
    A problem occurred evaluating project ‘:app’.
    > java.lang.UnsupportedClassVersionError: com/android/build/gradle/AppPlugin : Unsupported major.minor version 52.0

    * 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
    Could not install the app on the device, read the error above for details.
    Make sure you have an Android emulator running or a device connected and have
    set up your Android development environment:
    https://facebook.github.io/react-native/docs/getting-started.html

    قبلا با انروید استدیو رو شبیه ساز میاوردم ولی واسه موارد دیگه به مشکل خوردم.

    با فی*تر شکن و وی *ی ان و همه چیز امتحان کردم بازم خطا میده

    اگه ممکنه راهنمایی کنید

    #23072 پاسخ

    سلام.نسخه 8 جاوا رو نصب کنید

    #23146 پاسخ
    علیرضا مختاری
    میهمان

    Starting JS server…
    Building and installing the app on the device (cd android && gradlew.bat installDebug)…

    FAILURE: Build failed with an exception.

    * What went wrong:
    A problem occurred configuring root project ‘appli’.
    > Could not resolve all files for configuration ‘:classpath’.
    > Could not find com.android.tools.build:gradle:3.1.4.
    Searched in the following locations:
    https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/3.1.4/gradle-3.1.4.pom
    https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/3.1.4/gradle-3.1.4.jar
    https://jcenter.bintray.com/com/android/tools/build/gradle/3.1.4/gradle-3.1.4.pom
    https://jcenter.bintray.com/com/android/tools/build/gradle/3.1.4/gradle-3.1.4.jar
    Required by:
    project :

    * 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 8s
    Could not install the app on the device, read the error above for details.
    Make sure you have an Android emulator running or a device connected and have
    set up your Android development environment:
    https://facebook.github.io/react-native/docs/getting-started.html

    چطوری این ارور را حل کنم؟

    #23233 پاسخ
    mehdi_biniaz
    مشارکت کننده

    با تشکر
    بله جاوا 8 نصب کردم و مشکل بر طرف شد

    #24651 پاسخ
    mohsen1473
    مشارکت کننده

    سلام من جاوا 8 رو هم نصب کردم باز ارور میده :

    Starting JS server…
    Building and installing the app on the device (cd android && gradlew.bat installDebug)…

    FAILURE: Build failed with an exception.

    * What went wrong:
    A problem occurred configuring root project ‘aramesh’.
    > Could not resolve all files for configuration ‘:classpath’.
    > Could not resolve com.android.tools.build:gradle:3.1.4.
    Required by:
    project :
    > Could not resolve com.android.tools.build:gradle:3.1.4.
    > Could not get resource ‘https://jcenter.bintray.com/com/android/tools/build/gradle/3.1.4/gradle-3.1.4.pom’.
    > Could not GET ‘https://jcenter.bintray.com/com/android/tools/build/gradle/3.1.4/gradle-3.1.4.pom’.
    > Connect to jcenter.bintray.com:443 [jcenter.bintray.com/75.126.118.188] failed: Connection timed out: connect

    * 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 23s
    Could not install the app on the device, read the error above for details.
    Make sure you have an Android emulator running or a device connected and have
    set up your Android development environment:
    https://facebook.github.io/react-native/docs/getting-started.html

    #24657 پاسخ
    سلام
    میهمان

    مشکل از تحریمه،از وب سایت shecan.ir استفاده کنید و دستور رو مجددا اجرا کنید

    #24882 پاسخ
    milad123
    مشارکت کننده

    سلام برای من هم این ارور رو میده الته طبق سایت react-native من اومدم sdk 27 رو نصب کردم از فیلتر شکنی هم که گفتین استفاده کردم جالب اینجاست که تو اندروید استدیو دکمه run رو میزنم راحت شبیه ساز اجرا میشه مشکل چیه؟
    * Where:
    Build file ‘F:\react-native\AwesomeProject\android\app\build.gradle’ line: 1

    * What went wrong:
    A problem occurred evaluating project ‘:app’.
    > java.lang.UnsupportedClassVersionError: com/android/build/gradle/AppPlugin : Unsupported major.minor version 52.0

    * 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 2s
    Could not install the app on the device, read the error above for details.
    Make sure you have an Android emulator running or a device connected and have
    set up your Android development environment:
    https://facebook.github.io/react-native/docs/getting-started.html

    #24885 پاسخ
    مهدی
    میهمان

    JDK رو به نسخه 1.8 بروز رسانی کنید
    و JAVA_HOME رو به آدرس پوشه نسخه جدید JDK تغییر بدید

    #24886 پاسخ
    milad123
    مشارکت کننده

    نصب کردم ولی باز ارور میده

    #24888 پاسخ
    milad123
    مشارکت کننده

    الان این ارور رومیده
    project :app > com.facebook.react:react-native:0.57.8

    * 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 2m 14s
    1 actionable task: 1 executed
    Could not install the app on the device, read the error above for details.
    Make sure you have an Android emulator running or a device connected and have
    set up your Android development environment:
    https://facebook.github.io/react-native/docs/getting-started.html

    #24891 پاسخ

    یک پروژه با نسخه ها ی پایین تر مثل 0.55.4 ایجاد کنید
    \react-native init –version=”0.55.4″ test

    #24892 پاسخ
    milad123
    مشارکت کننده

    درست شد از speed v*n استفاده کردم و یه بار هم سیستم رو خاموش روشن کردم

    #26590 پاسخ
    azadgh95
    مشارکت کننده

    من هم همین مشکل داشتم و jdk رو تغییر دادم به ورژن 1.8.0.201
    و همچنین بعدش sdk رو آپدیت کردم به بروز ترین ورژن که خداروشکر مشکلم حل شد

    #26790 پاسخ
    arash
    مشارکت کننده

    سلام
    همه این کارهایی که دوستان اشاره کرده اند من انجام دادم اما هنوز مشکل برطرف نشده و از نسخه های پایین تر برای ساخت پروژه استفاده می کنم. اگه راه حل دیگه ای به نظرتون میرسه لطفا اعلام کنید.
    ممنون

    #26865 پاسخ
    arash
    مشارکت کننده

    سلام
    بالاخره مشکل حل شد.
    ممنون از شما

در حال نمایش 15 نوشته (از کل 23)
پاسخ به: اجرا نشدن react-native run-android
اطلاعات شما: