淡然529
淡然529
  • 发布:2024-03-08 15:04
  • 更新:2024-07-11 16:39
  • 阅读:275

#插件讨论# 【 uts-progressNotification - DCloud移动团队 】安卓打包失败

分类:uni-app
关联插件: uts-progressNotification

安卓打包失败
时间: 2024-03-08 14:52:42 类型: Android云端证书 打包失败 错误日志: https://app.liuyingyong.cn/build/errorLog/76311990-dd18-11ee-974a-5f71ce4aa84d
[HBuilder] 14:58:36.981 Warning: Mapping new ns http://schemas.android.com/repository/android/common/02 to old ns http://schemas.android.com/repository/android/common/01
[HBuilder] 14:58:36.982 Warning: Mapping new ns http://schemas.android.com/repository/android/generic/02 to old ns http://schemas.android.com/repository/android/generic/01
[HBuilder] 14:58:36.982 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/02 to old ns http://schemas.android.com/sdk/android/repo/addon2/01
[HBuilder] 14:58:36.983 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/03 to old ns http://schemas.android.com/sdk/android/repo/addon2/01
[HBuilder] 14:58:36.983 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/02 to old ns http://schemas.android.com/sdk/android/repo/repository2/01
[HBuilder] 14:58:36.984 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/03 to old ns http://schemas.android.com/sdk/android/repo/repository2/01
[HBuilder] 14:58:36.984 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/03 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01
[HBuilder] 14:58:36.984 Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/02 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01
[HBuilder] 14:58:36.985 Warning: unexpected element (uri:"", local:"extension-level"). Expected elements are <{}codename>,<{}layoutlib>,<{}api-level>
[HBuilder] 14:58:36.985 Warning: unexpected element (uri:"", local:"base-extension"). Expected elements are <{}codename>,<{}layoutlib>,<{}api-level>
[HBuilder] 14:58:36.985 e: file://uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:226:12 Reference has a nullable type '(() -> Unit)?', use explicit '?.invoke()' to make a function-like call instead
[HBuilder] 14:58:36.986
[HBuilder] 14:58:36.986 FAILURE: Build failed with an exception.
[HBuilder] 14:58:36.986
[HBuilder] 14:58:36.986 * What went wrong:
[HBuilder] 14:58:36.987 Execution failed for task ':uni_modules:uts-progressNotification:compileReleaseKotlin'.
[HBuilder] 14:58:36.987 > A failure occurred while executing org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction
[HBuilder] 14:58:36.987 > Compilation error. See log for more details

2024-03-08 15:04 负责人:无 分享
已邀请:
DCloud_Android_THB

DCloud_Android_THB

我看一下

  • 淡然529 (作者)

    我发现为什么会出现这个问题了,原因是我使用的是HBuilderX Alpha版,今天刚刚更新了导致出现这个问题。我现在用HBuilderX正式版是ok的,麻烦你们查一下是啥原因造成的,正式版3.99,Alpha版版本是4.02

    2024-03-08 15:50

  • DCloud_Android_THB

    回复 2***@qq.com: 我刚更新了一个版本 1.1.0 , 你再试试

    2024-03-08 16:28

  • 淡然529 (作者)

    回复 DCloud_Android_THB: 使用的是HBuilderX Alpha版试试?

    2024-03-08 16:31

  • DCloud_Android_THB

    回复 2***@qq.com: 对

    2024-03-08 16:36

  • 淡然529 (作者)

    回复 DCloud_Android_THB: 还是同样的问题,没有变化

    2024-03-08 16:37

  • DCloud_Android_THB

    回复 2***@qq.com: 你确定一下版本是不是1.1.0

    2024-03-08 16:38

  • DCloud_Android_THB

    回复 2***@qq.com: 清除unpackage目录

    2024-03-08 16:43

  • 淡然529 (作者)

    回复 DCloud_Android_THB: 已经可以了,谢谢

    2024-03-11 14:26

  • j***@outlook.com

    回复 2***@qq.com: 后面怎么解决的啊,我也遇到了一样的问题

    2024-04-09 20:53

2***@qq.com

2***@qq.com

我也是同样的问题。作者是怎么解决的啊?编辑器版本4.23,已经是1.1.0版本。依旧报错。最奇怪的是基本相同的代码逻辑。另一个项目上可以正常打包。
Warning: Mapping new ns http://schemas.android.com/repository/android/common/02 to old ns http://schemas.android.com/repository/android/common/01
Warning: Mapping new ns http://schemas.android.com/repository/android/generic/02 to old ns http://schemas.android.com/repository/android/generic/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/02 to old ns http://schemas.android.com/sdk/android/repo/addon2/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/03 to old ns http://schemas.android.com/sdk/android/repo/addon2/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/02 to old ns http://schemas.android.com/sdk/android/repo/repository2/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/03 to old ns http://schemas.android.com/sdk/android/repo/repository2/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/03 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01
Warning: Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/02 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01
Warning: unexpected element (uri:\"\", local:\"extension-level\"). Expected elements are <{}codename>,<{}layoutlib>,<{}api-level>
Warning: unexpected element (uri:\"\", local:\"base-extension\"). Expected elements are <{}codename>,<{}layoutlib>,<{}api-level>
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:93:8 Expecting property name or receiver type
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:93:8 Unexpected tokens (use ';' to separate expressions on the same line)
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:93:39 Expecting '->' or ','
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:97:54 Expecting ')'
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:97:55 Unexpected tokens (use ';' to separate expressions on the same line)
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:97:105 Expecting an element
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:105:54 Expecting ')'
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:105:55 Unexpected tokens (use ';' to separate expressions on the same line)
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:105:112 Expecting an element
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:108:54 Expecting ')'
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:108:55 Unexpected tokens (use ';' to separate expressions on the same line)
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:108:112 Expecting an element
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:138:43 Expecting ')'
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:138:44 Unexpected tokens (use ';' to separate expressions on the same line)
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:138:66 Expecting an element
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:93:9 Variable expected
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:93:11 Cannot infer a type for this parameter. Please specify it explicitly.
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:93:21 Cannot infer a type for this parameter. Please specify it explicitly.
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:93:32 Cannot infer a type for this parameter. Please specify it explicitly.
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:93:45 Type mismatch: inferred type is CreateNotificationProgressOptions but (???, ???, ???) -> Unit was expected
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:94:9 Unresolved reference: progress
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:97:40 Type mismatch: inferred type is String? but String was expected
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:101:23 Unresolved reference: progress
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:105:40 Type mismatch: inferred type is String? but String was expected
e: file://[PackagePath]/wgtRoot/UNI5C357DD/uni_modules/uts-progressNotification/utssdk/app-android/src/index.kt:108:40 Type mismatch: inferred type is String? but String was expected

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':uni_modules:uts-progressNotification:compileReleaseKotlin'.

    A failure occurred while executing org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction
    Compilation error. See log for more details

  • 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 29s
Error code = -5000
Error message:
UTS plugin @ utssdk uts-progressNotification compile error!

  • 淡然529 (作者)

    我是更新了版本就可以了

    2024-07-11 17:21

  • 2***@qq.com

    回复 淡然529:我发现没问题的项目,打包过程中不会去第三方下载依赖。有问题的项目,打包过程中底部终端会提示去第三方下载依赖,然后就报错,日志中让升级最新的版本。

    2024-07-11 17:43

  • 2***@qq.com

    回复 淡然529: 我怀疑是不是项目打包的时候,没有使用本地uni_modules中的插件,从第三方下载去了。但是第三方下载的还是旧的,所以造成了这个问题。上边的报错中也有 Warning:重定向的提示

    2024-07-11 17:48

  • DCloud_Android_THB

    回复 2***@qq.com: 你删掉unpackage目录再打包试试

    2024-07-12 09:39

要回复问题请先登录注册