/C:/FlutterSdk/flutter/.pub-cache/hosted/pub.dartlang.org/fl_chart-0.50.5/lib/src/chart/pie_chart/pie_chart.dart:42:29: Error: Method 'addPostFrameCallback' cannot be called on 'WidgetsBinding?' because it is potentially null.
- 'WidgetsBinding' is from 'package:flutter/src/widgets/binding.dart' ('/C:/FlutterSdk/flutter/packages/flutter/lib/src/widgets/binding.dart'). Try calling using ?. instead. WidgetsBinding.instance.addPostFrameCallback((_) { ^^^^^^^^^^^^^^^^^^^^
FAILURE: Build failed with an exception.
Where: Script 'C:\FlutterSdk\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1102
What went wrong: Execution failed for task ':app:compileFlutterBuildDebug'.
Process 'command 'C:\FlutterSdk\flutter\bin\flutter.bat'' finished with non-zero exit value 1
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 33s Running Gradle task 'assembleDebug'... 38.2s Exception: Gradle task assembleDebug failed with exit code 1