flutter / flutter

Flutter makes it easy and fast to build beautiful apps for mobile and beyond
https://flutter.dev
BSD 3-Clause "New" or "Revised" License
164.9k stars 27.16k forks source link

Build failed while running for windows #105427

Closed chandra-sekhar-mantralabs closed 2 years ago

chandra-sekhar-mantralabs commented 2 years ago

Steps to Reproduce

  1. Execute flutter run on the code sample
  2. ...
  3. ...

Expected results:

Actual results:

Code sample ```dart ```
Logs ``` ``` ``` ``` ``` ```

while running my application for windows build is being failed.

logs - /C:/flutter/.pub-cache/hosted/pub.dartlang.org/provider-5.0.0/lib/src/inherited_provider.dart(391,26): warning G1E0FE241: Operand of null-aware operatio n '!' has type 'SchedulerBinding' which excludes null. [C:\Users\ChandraSekharSahu\Documents\GitHub\Flutter-Responsive-Admin-Panel-or-Dashboard\build\wi ndows\flutter\flutter_assemble.vcxproj] /C:/flutter/.pub-cache/hosted/pub.dartlang.org/fl_chart-0.36.1/lib/src/chart/pie_chart/pie_chart.dart(38,20): warning G1E0FE241: Operand of null-aware o peration '?.' has type 'WidgetsBinding' which excludes null. [C:\Users\ChandraSekharSahu\Documents\GitHub\Flutter-Responsive-Admin-Panel-or-Dashboard\bu ild\windows\flutter\flutter_assemble.vcxproj] /C:/flutter/.pub-cache/hosted/pub.dartlang.org/platform-3.0.0/lib/src/interface/local_platform.dart(46,19): error G75B77105: Member not found: 'packageR oot'. [C:\Users\ChandraSekharSahu\Documents\GitHub\Flutter-Responsive-Admin-Panel-or-Dashboard\build\windows\flutter\flutter_assemble.vcxproj] C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(245,5): error MSB8066: Custom build for 'C :\Users\ChandraSekharSahu\Documents\GitHub\Flutter-Responsive-Admin-Panel-or-Dashboard\build\windows\CMakeFiles\aa744acba78720dc15af983a1c83c366\flutter _windows.dll.rule;C:\Users\ChandraSekharSahu\Documents\GitHub\Flutter-Responsive-Admin-Panel-or-Dashboard\build\windows\CMakeFiles\4cba46e5d874f3594771a c924c181e24\flutter_assemble.rule;C:\Users\ChandraSekharSahu\Documents\GitHub\Flutter-Responsive-Admin-Panel-or-Dashboard\windows\flutter\CMakeLists.txt ' exited with code 1. [C:\Users\ChandraSekharSahu\Documents\GitHub\Flutter-Responsive-Admin-Panel-or-Dashboard\build\windows\flutter\flutter_assemble.vc xproj] Building Windows application... Exception: Build process failed.

exaby73 commented 2 years ago

Hello @chandra-sekhar-mantralabs. Looks like you're using a version of fl_chart that doesn't support Flutter 3.0. Please upgrade to the latest version specified and retry your build.

stuartmorgan commented 2 years ago

@exaby73 Dart warnings are not fatal, so wouldn't cause build failures.

This is a duplicate of https://github.com/flutter/flutter/issues/96711

github-actions[bot] commented 2 years ago

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.