zubairehman / flutter_boilerplate_project

A boilerplate project created in flutter using MobX and Provider.
http://zubairehman.surge.sh/
MIT License
2.26k stars 908 forks source link

flutter packages pub run build_runner build --delete-conflicting-outputs Not Working For flutter_1.22.4 #78

Closed hemantsavkar closed 3 years ago

hemantsavkar commented 3 years ago

Hi @zubairehman , For Some Reason Flutter Started Asking For Upgrade To Embed v2; i did all package upgrade as well. When all got upgraded, now code generator is not working with below exceptioon

Hemants-MacBook-Pro:MobileApp_Marketing hemantsavkar$ flutter packages pub run build_runner build --delete-conflicting-outputs Failed to precompile build_runner:build_runner: ../../Installations/flutter_1.22.4/.pub-cache/hosted/pub.dartlang.org/build_resolvers-1.4.0/lib/src/resolver.dart:437:23: Error: Method not found: 'FeatureSet.fromEnableFlags2'. return FeatureSet.fromEnableFlags2( ^^^^^^^^^^^^^^^^ ../../Installations/flutter_1.22.4/.pub-cache/hosted/pub.dartlang.org/build_resolvers-1.4.0/lib/src/resolver.dart:440:23: Error: Method not found: 'FeatureSet.fromEnableFlags2'. return FeatureSet.fromEnableFlags2( ^^^^^^^^^^^^^^^^ ../../Installations/flutter_1.22.4/.pub-cache/hosted/pub.dartlang.org/dart_style-1.3.10/lib/src/source_visitor.dart:2619:21: Error: The getter 'externalKeyword' isn't defined for the class 'TopLevelVariableDeclaration'.

Flutter Doctor Output

Hemants-MacBook-Pro:MobileApp_Marketing hemantsavkar$ flutter doctor Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel stable, 1.22.4, on Mac OS X 10.15.7 19H2 darwin-x64, locale en-IN)

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.3) [!] Xcode - develop for iOS and macOS (Xcode 11.6) ✗ CocoaPods installed but not working. You appear to have CocoaPods installed but it is not working. This can happen if the version of Ruby that CocoaPods was installed with is different from the one being used to invoke it. This can usually be fixed by re-installing CocoaPods. For more info, see https://github.com/flutter/flutter/issues/14293. To re-install CocoaPods, run: sudo gem install cocoapods [!] Android Studio (not installed) [✓] VS Code (version 1.49.1) [✓] Connected device (1 available)

! Doctor found issues in 2 categories. Hemants-MacBook-Pro:MobileApp_Marketing hemantsavkar$

pubspec.yaml

name: doctorappointment description: doctorappointment App.

version: 1.0.0+7A

environment: sdk: ">=2.7.0 <3.0.0"

dependencies: flutter: sdk: flutter

flutter_localizations: sdk: flutter flutter_cupertino_localizations: ^1.0.1

cupertino_icons: ^1.0.0

shared_preferences: ^0.5.6

http: ^0.12.0+4

flutter_launcher_icons: ^0.7.4

f_logs: ^1.2.2

mobx: ^1.2.1 flutter_mobx: ^1.1.0 mobx_codegen: ^1.1.0

provider: ^4.0.1

validators: ^2.0.0+1

dio: 3.0.8

flushbar: 1.10.2

material_dialog: ^0.0.9 firebase_core: ^0.5.3 firebase_analytics: ^5.0.11 firebase_auth: ^0.18.4+1 firebase_storage: ^5.2.0 cloud_firestore: ^0.14.4 flutter_facebook_login: ^3.0.0 google_sign_in: ^4.5.1 fluttertoast: ^3.1.3

flutter_youtube: ^2.0.0

photo_view: ^0.9.2

font_awesome_flutter: ^8.8.1

highlight_text: ^0.7.2

google_fonts: ^1.1.0

extended_image: ^0.9.0

material_segmented_control: ^2.1.0+1

url_launcher: ^5.4.10

timeline_tile: ^0.1.0

percent_indicator: "^2.1.5"

flutter_widget_from_html: ^0.4.2

date_format: ^1.0.8

flutter_money_formatter: ^0.8.3

flutter_rating_bar: ^3.0.1+1

maps_launcher: ^1.2.1

file_picker: ^2.1.0

mime: ^0.9.6+3

inject: git: url: https://github.com/google/inject.dart.git path: package/inject ref: 7c3cbf6

dependency_overrides: source_gen: ^0.9.6 analyzer: ^0.39.17 intl: ^0.16.1

dev_dependencies: flutter_test: sdk: flutter

build_resolvers: 1.4.0 json_serializable: ^3.4.1 build_runner: ^1.10.0 inject_generator: git: url: https://github.com/google/inject.dart.git path: package/inject_generator ref: 7c3cbf6

flutter_icons: image_path: "assets/icons/ic_launcher.png" android: true ios: true

flutter: assets:

zubairehman commented 3 years ago

I have updated the project, please check this thread: https://github.com/zubairehman/flutter-boilerplate-project/issues/80