samples icon indicating copy to clipboard operation
samples copied to clipboard

[add-to-app] Build failed with an exception.

Open admsasha opened this issue 1 year ago • 1 comments

I'm trying to build samples/add_to_app/android_view

FAILURE: Build failed with an exception.

  • What went wrong: A problem was found with the configuration of task ':flutter:mergeDebugAndroidTestAssets' (type 'MergeSourceSetFolders').
    • Gradle detected a problem with the following location: '/home/sasha/AndroidStudioProjects/test/flutter/flutter_samples/add_to_app/android_view/flutter_module_using_plugin/.android/Flutter/build/intermediates/library_assets/debug/packageDebugAssets/out'.

      Reason: Task ':flutter:mergeDebugAndroidTestAssets' uses this output of task ':flutter:copyFlutterAssetsDebug' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed.

      Possible solutions:

      1. Declare task ':flutter:copyFlutterAssetsDebug' as an input of ':flutter:mergeDebugAndroidTestAssets'.
      2. Declare an explicit dependency on ':flutter:copyFlutterAssetsDebug' from ':flutter:mergeDebugAndroidTestAssets' using Task#dependsOn.
      3. Declare an explicit dependency on ':flutter:copyFlutterAssetsDebug' from ':flutter:mergeDebugAndroidTestAssets' using Task#mustRunAfter.

how and where to fix it?

admsasha avatar Oct 11 '24 05:10 admsasha

PTAL @ericwindmill

domesticmouse avatar Oct 13 '24 02:10 domesticmouse