NativeScript / NativeScript/android

Build error in production build with signing

Đang mở
#1,531 1 bình luận 1 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Ngôn ngữ chính
C++
Star
563
Fork
144
Merge trung bình
10 giờ 46 phút
Pull request đã merge (30 ngày)
14

Mô tả

Environment
Provide version numbers for the following components (information can be retrieved by running tns info in your project folder or by inspecting the package.json of the project):

  • CLI: 6.1.0
  • Cross-platform modules: 6.1.2
  • Android Runtime: 6.1.2
  • Plugin(s): no plugin

Describe the bug
When I want to build my app with production build and signing process, I get the following errors:

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:lintVitalRelease'.
> Could not resolve all files for configuration ':app:lintClassPath'.
   > Could not find lint-gradle.jar (com.android.tools.lint:lint-gradle:26.5.0).
     Searched in the following locations:
         https://dl.google.com/dl/android/maven2/com/android/tools/lint/lint-gradle/26.5.0/lint-gradle-26.5.0.jar
   > Could not find lint.jar (com.android.tools.lint:lint:26.5.0).
     Searched in the following locations:
         https://dl.google.com/dl/android/maven2/com/android/tools/lint/lint/26.5.0/lint-26.5.0.jar
   > Could not find lint-checks.jar (com.android.tools.lint:lint-checks:26.5.0).
     Searched in the following locations:
         https://dl.google.com/dl/android/maven2/com/android/tools/lint/lint-checks/26.5.0/lint-checks-26.5.0.jar
   > Could not find lint-api.jar (com.android.tools.lint:lint-api:26.5.0).
     Searched in the following locations:
         https://dl.google.com/dl/android/maven2/com/android/tools/lint/lint-api/26.5.0/lint-api-26.5.0.jar
   > Could not find intellij-core.jar (com.android.tools.external.com-intellij:intellij-core:26.5.0).
     Searched in the following locations:
         https://dl.google.com/dl/android/maven2/com/android/tools/external/com-intellij/intellij-core/26.5.0/intellij-core-26.5.0.jar
   > Could not find kotlin-compiler.jar (com.android.tools.external.com-intellij:kotlin-compiler:26.5.0).
     Searched in the following locations:
         https://dl.google.com/dl/android/maven2/com/android/tools/external/com-intellij/kotlin-compiler/26.5.0/kotlin-compiler-26.5.0.jar
   > Could not find uast.jar (com.android.tools.external.org-jetbrains:uast:26.5.0).
     Searched in the following locations:
         https://dl.google.com/dl/android/maven2/com/android/tools/external/org-jetbrains/uast/26.5.0/uast-26.5.0.jar

* 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 5m 30s
Command gradlew.bat failed with exit code 1

Note: Normal build just works fine (with tns run android command)

To Reproduce
Just build the project with the following command:

tns build android --release --key-store-path my-release-key.keystore --key-store-password YOUR_PASS --key-store-alias YOUR_NAME --key-store-alias-password YOUR_PASS --bundle --env.uglify --env.aot

Expected behavior
No error.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Bắt đầu bằng cách tái hiện lệnh release với các phiên bản NativeScript đã báo cáo và kiểm tra đường dẫn build Android cho tác vụ :app:lintVitalRelease cùng các dependency lintClassPath của tác vụ này. So sánh production build bị lỗi với build tns run android đang hoạt động; được xem là hoàn tất khi signed release build hoàn thành mà không có lỗi thiếu các lint artifact.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
android
Lĩnh vực
build-system, mobile
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
35/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.