6.Flutter运行Andriod真机报错

2020-05-28  本文已影响0人  凯司机

报错内容如下:

FAILURE: Build failed with an exception.                                                                         

* What went wrong:                                                                                               

Could not determine the dependencies of task ':app:compileDebugJavaWithJavac'.                                   

> Could not resolve all task dependencies for configuration ':app:debugCompileClasspath'.                         

  > Could not resolve io.flutter:flutter_embedding_debug:1.0.0-6bc433c6b6b5b98dcf4cc11aff31cdee90849f32.         

    Required by:                                                                                                 

        project :app                                                                                             

      > Skipped due to earlier error                                                                             

      > Skipped due to earlier error                                                                             

      > Skipped due to earlier error                                                                             

  > Could not resolve io.flutter:armeabi_v7a_debug:1.0.0-6bc433c6b6b5b98dcf4cc11aff31cdee90849f32.               

    Required by:                                                                                                 

        project :app                                                                                             

      > Skipped due to earlier error                                                                             

      > Skipped due to earlier error                                                                             

      > Skipped due to earlier error                                                                             

  > Could not resolve io.flutter:x86_debug:1.0.0-6bc433c6b6b5b98dcf4cc11aff31cdee90849f32.                       

    Required by:                                                                                                 

        project :app                                                                                             

      > Skipped due to earlier error                                                                             

      > Skipped due to earlier error                                                                             

      > Skipped due to earlier error                                                                             

  > Could not resolve io.flutter:x86_64_debug:1.0.0-6bc433c6b6b5b98dcf4cc11aff31cdee90849f32.                   

    Required by:                                                                                                 

        project :app                                                                                             

      > Skipped due to earlier error                                                                             

      > Skipped due to earlier error                                                                             

      > Skipped due to earlier error                                                                             

* 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 5s                                                                                             

Running Gradle task 'assembleDebug'...                                                                           

Running Gradle task 'assembleDebug'... Done                      131.6s (!)

Exception: Gradle task assembleDebug failed with exit code 1

报错信息截图

解决办法:

1.在Terminal里:    cd~项目根目录    

2.在Terminal里执行: flutter clean ,清理一下项目缓存就可以了

3.重新运行项目

上一篇 下一篇

猜你喜欢

热点阅读