gpt4 book ai didi

flutter - Gradle任务assembleDebug失败,退出代码为1,如何解决此问题?

转载 作者:行者123 更新时间:2023-12-03 03:04:47 33 4
gpt4 key购买 nike

请看下面的错误

    Launching lib/main.dart on SM G965F in debug mode...
Running Gradle task 'assembleDebug'...

编译器消息:
    ../../../../minhpham/flutter/.pub-cache/hosted/pub.dartlang.org/cached_network_image-1.1.3/lib/src/cached_network_image_provider.dart:42:24: Error: The method 'CachedNetworkImageProvider.load' has fewer positional arguments than those of overridden method 'ImageProvider.load'.
ImageStreamCompleter load(CachedNetworkImageProvider key) {
^
../../../../minhpham/flutter/packages/flutter/lib/src/painting/image_provider.dart:403:24: Context: This is the overridden method ('load').
ImageStreamCompleter load(T key, DecoderCallback decode);
^
Target kernel_snapshot failed: Exception: Errors during snapshot creation: null
build failed.

FAILURE: Build failed with an exception.

* Where:
Script '/Users/minhpham/flutter/packages/flutter_tools/gradle/flutter.gradle' line: 780

* What went wrong:
Execution failed for task ':app:compileFlutterBuildDebug'.
> Process 'command '/Users/minhpham/flutter/bin/flutter'' finished with non-zero exit value 1

* 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 18s
Finished with error: Gradle task assembleDebug failed with exit code 1

和请参阅日志提示
    2019-12-21 19:27:55.477 4569-5133/? D/bauth_FPBAuthService: thread id : 1, preenroll_flag : 0, nd cnt : 0, cso : 0, et : 0
2019-12-21 19:27:55.477 4569-5133/? D/bauth_FPBAuthService: FPBAuthService, 9983
2019-12-21 19:27:55.519 8312-8312/? I/SKBD: anc isTosAccept false
2019-12-21 19:27:55.921 8312-8312/? I/chatty: uid=10160(com.sec.android.inputmethod) identical 2 lines
2019-12-21 19:27:56.123 8312-8312/? I/SKBD: anc isTosAccept false
2019-12-21 19:27:56.257 4337-10083/? V/APM_AudioPolicyManager: getAudioPolicyConfig: audioParam;outDevice
2019-12-21 19:27:56.258 4337-10083/? V/APM_AudioPolicyManager: getNewOutputDevice() selected device 0
2019-12-21 19:27:56.258 4337-10083/? V/APM_AudioPolicyManager: ### curdevice : 2
2019-12-21 19:27:56.324 8312-8312/? I/SKBD: anc isTosAccept false
2019-12-21 19:27:56.478 4569-5133/? D/bauth_FPBAuthService: pcf : 0x1012, 0 ,1 ,0 ,0 ,0 ,0,
2019-12-21 19:27:56.478 4569-5133/? D/bauth_FPBAuthService: thread id : 1, preenroll_flag : 0, nd cnt : 0, cso : 0, et : 0
2019-12-21 19:27:56.478 4569-5133/? D/bauth_FPBAuthService: FPBAuthService, 9983
2019-12-21 19:27:56.524 8312-8312/? I/SKBD: anc isTosAccept false
2019-12-21 19:27:56.598 11472-11472/? I/omobile.apploc: Explicit concurrent copying GC freed 18(32KB) AllocSpace objects, 0(0B) LOS objects, 55% free, 4MB/10MB, paused 670us total 139.080ms
2019-12-21 19:27:56.725 8312-8312/? I/SKBD: anc isTosAccept false

最佳答案

您需要升级到cached_network_image 2.0.0-rc

如何安装?
将此添加到包的pubspec.yaml文件中:

dependencies:
cached_network_image: ^2.0.0-rc

同样,他们在pub.dev Page中也提到了此问题

If you are experiencing one of the following errors upgrade to 2.0.0-rc.


The method 'ScaledFileImage.load' has fewer positional arguments than those of overridden method 'ImageProvider.load'

要么
The method 'CachedNetworkImageProvider.load' has fewer positional arguments than those of overridden method 'ImageProvider.load'

关于flutter - Gradle任务assembleDebug失败,退出代码为1,如何解决此问题?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59437932/

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