gpt4 book ai didi

ionic-framework - Ionic 3 项目和插件人行横道错误

转载 作者:行者123 更新时间:2023-12-03 15:13:08 25 4
gpt4 key购买 nike

我有一个 Ionic 3 项目,当我运行“ionic cordova run android --prod”时,我看到

此错误:

ANDROID_HOME=C:\Users\asus\AppData\Local\Android\sdk\ 
JAVA_HOME=C:\Program Files\Java\jdk1.8.0_131\
Subproject Path: CordovaLib null
The Task.leftShift(Closure) method has been deprecated and
is scheduled to be removed in Gradle 5.0. Please use
Task.doLast(Action) instead.
at build_86b8k75dm7qqz7n5jyg9xp8kh.run(D:\project\ionic\MyProject\platforms\android\build.gradle:138) org.xwalk:xwalk_core_library:23+ The JavaCompile.setDependencyCacheDir() method has been deprecated and is scheduled to be removed in Gradle 4.0.

Incremental java compilation is an incubating feature. The TaskInputs.source(Object) method has been deprecated and is scheduled to be removed in Gradle 4.0. Please use TaskInp uts.file(Object).skipWhenEmpty() instead.

FAILURE: Build failed with an exception.

* What went wrong:

BUILD FAILED

Total time: 15.644 secs A problem occurred configuring root project 'android'.
> Could not resolve all dependencies for configuration ':_armv7DebugApkCopy'.
> Could not resolve org.xwalk:xwalk_core_library:23+.
Required by:
project :
> Could not resolve org.xwalk:xwalk_core_library:23+.
> Failed to list versions for org.xwalk:xwalk_core_library.
> Unable to load Maven meta-data from https://download.01.org/crosswalk/releases/crosswalk/android/maven2/org /xwalk/xwalk_core_library/maven-metadata.xml.
> Could not GET 'https://download.01.org/crosswalk/releases/crosswalk/android/maven2/org/xwalk/xwalk_core_ library/maven-metadata.xml'. Received status code 503 from server: Service Unavailable

* Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Error: cmd: Command failed with exit code 1 Error output: FAILURE: Build failed with an exception.

* What went wrong: A problem occurred configuring root project 'android'.
> Could not resolve all dependencies for configuration ':_armv7DebugApkCopy'.
> Could not resolve org.xwalk:xwalk_core_library:23+.
Required by:
project :
> Could not resolve org.xwalk:xwalk_core_library:23+.
> Failed to list versions for org.xwalk:xwalk_core_library.
> Unable to load Maven meta-data from https://download.01.org/crosswalk/releases/crosswalk/android/maven2/org /xwalk/xwalk_core_library/maven-metadata.xml.
> Could not GET 'https://download.01.org/crosswalk/releases/crosswalk/android/maven2/org/xwalk/xwalk_core_ library/maven-metadata.xml'. Received status code 503 from server: Service Unavailable

* Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.


[ERROR] Cordova encountered an error.
You may get more insight by running the Cordova command above directly.

[ERROR] An error occurred while running cordova run android (exit code 1).

在运行 Ionic 之前我没有收到这个错误。

最佳答案

01.org 服务器似乎已关闭。因此,在服务器重新上线之前,您可以要求 Gradle 使用 Crosswalk 的本地副本。

从上一小时开始,我遇到了同样的问题。以下解决方案对我有用。

开通 平台\android\cordova-plugin-crosswalk-webview\*-xwalk.gradle 项目目录中的文件,其中 * 是您的项目名称。

寻找部分 -

dependencies {
compile xwalkSpec
}

通过键入 ,将其替换为您在 Chrome 开发人员工具中找到的确切 Crosswalk 版本。 window.navigator.userAgent 在您的开发者工具控制台中。

所以你的最终数据看起来像这样 -
dependencies {
compile 'org.xwalk:xwalk_core_library:23.53.589.4'
}

关于ionic-framework - Ionic 3 项目和插件人行横道错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46012838/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com