Home > Software design >  Error when running flutter pub run build_runner build --delete-conflicting-outputs
Error when running flutter pub run build_runner build --delete-conflicting-outputs

Time:09-21

I'm trying to integrate a smart contract into my flutter and I'm referring to error pic

CodePudding user response:

After updating Flutter to version 2.5.2, there were some conflicts even though no code was changed, therefore I use any in pubspec.yaml.

 dependencies:
      flutter:
        sdk: flutter
      moor: ^4.5.0
      provider: ^5.0.0
      path_provider: any
      path: ^1.8.0
    
    dev_dependencies:
      flutter_test:
        sdk: flutter
      moor_generator: any
      build_runner: any
      flutter_launcher_icons: any

CodePudding user response:

Try this

File => Invalidate caches / Restart

Run following command:

flutter clean

flutter pub get

flutter packages pub run build_runner build --delete-conflicting-outputs  

 

About --delete-conflicting-outputs

Assume conflicting outputs in the users package are from previous builds, and skip the user prompt that would usually be provided.

Reference

  • Related