/C:/Users/Rise%20Star/AppData/Local/Pub/Cache/hosted/pub.dev/agora_uikit-1.0.4/lib/controllers/rtm_client_event_handler.dart:76:7: Error: A value of
type 'Null Function(LocalInvitation)' can't be assigned to a variable of type 'dynamic Function(LocalInvitation, String)?'.
- 'LocalInvitation' is from 'package:agora_rtm/src/utils.dart' ('/C:/Users/Rise%20Star/AppData/Local/Pub/Cache/hosted/pub.dev/agora_rtm-1.5.9/lib/s
rc/utils.dart').
(AgoraRtmLocalInvitation invitation) {
^
/C:/Users/Rise%20Star/AppData/Local/Pub/Cache/hosted/pub.dev/agora_uikit-1.0.4/lib/controllers/rtm_client_event_handler.dart:81:7: Error: A value of
type 'void Function(LocalInvitation)' can't be assigned to a variable of type 'void Function(LocalInvitation, String)?'.
- 'LocalInvitation' is from 'package:agora_rtm/src/utils.dart' ('/C:/Users/Rise%20Star/AppData/Local/Pub/Cache/hosted/pub.dev/agora_rtm-1.5.9/lib/s
rc/utils.dart').
(AgoraRtmLocalInvitation invitation) {
^
/C:/Users/Rise%20Star/AppData/Local/Pub/Cache/hosted/pub.dev/flutterwave_standard-1.0.4/lib/view/payment_widget.dart:61:19: Error: No named paramete
r with the name 'primary'.
primary: widget.style.getButtonColor(),
^^^^^^^
/C:/src/flutter/packages/flutter/lib/src/material/elevated_button.dart:204:22: Context: Found this candidate, but the arguments don't match.
static ButtonStyle styleFrom({
^^^^^^^^^
Target kernel_snapshot_program failed: Exception
FAILURE: Build failed with an exception.
* Where:
Script 'C:\src\flutter\packages\flutter_tools\gradle\src\main\groovy\flutter.groovy' line: 1685
* What went wrong:
Execution failed for task ':app:compileFlutterBuildRelease'.
> Process 'command 'C:\src\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
BUILD FAILED in 26s
Running Gradle task 'assembleRelease'... 27.6s
Gradle task assembleRelease failed with exit code 1
having error while building apk i am using flutter version 3.27.1
/C:/Users/Rise%20Star/AppData/Local/Pub/Cache/hosted/pub.dev/agora_uikit-1.0.4/lib/controllers/rtm_client_event_handler.dart:76:7: Error: A value of
type 'Null Function(LocalInvitation)' can't be assigned to a variable of type 'dynamic Function(LocalInvitation, String)?'.
- 'LocalInvitation' is from 'package:agora_rtm/src/utils.dart' ('/C:/Users/Rise%20Star/AppData/Local/Pub/Cache/hosted/pub.dev/agora_rtm-1.5.9/lib/s
rc/utils.dart').
(AgoraRtmLocalInvitation invitation) {
^
/C:/Users/Rise%20Star/AppData/Local/Pub/Cache/hosted/pub.dev/agora_uikit-1.0.4/lib/controllers/rtm_client_event_handler.dart:81:7: Error: A value of
type 'void Function(LocalInvitation)' can't be assigned to a variable of type 'void Function(LocalInvitation, String)?'.
- 'LocalInvitation' is from 'package:agora_rtm/src/utils.dart' ('/C:/Users/Rise%20Star/AppData/Local/Pub/Cache/hosted/pub.dev/agora_rtm-1.5.9/lib/s
rc/utils.dart').
(AgoraRtmLocalInvitation invitation) {
^
/C:/Users/Rise%20Star/AppData/Local/Pub/Cache/hosted/pub.dev/flutterwave_standard-1.0.4/lib/view/payment_widget.dart:61:19: Error: No named paramete
r with the name 'primary'.
primary: widget.style.getButtonColor(),
^^^^^^^
/C:/src/flutter/packages/flutter/lib/src/material/elevated_button.dart:204:22: Context: Found this candidate, but the arguments don't match.
static ButtonStyle styleFrom({
^^^^^^^^^
Target kernel_snapshot_program failed: Exception
FAILURE: Build failed with an exception.
* Where:
Script 'C:\src\flutter\packages\flutter_tools\gradle\src\main\groovy\flutter.groovy' line: 1685
* What went wrong:
Execution failed for task ':app:compileFlutterBuildRelease'.
> Process 'command 'C:\src\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.
BUILD FAILED in 26s
Running Gradle task 'assembleRelease'... 27.6s
Gradle task assembleRelease failed with exit code 1
having error while building apk i am using flutter version 3.27.1
Share Improve this question edited Mar 21 at 6:06 Abhijith 2,3272 gold badges17 silver badges43 bronze badges asked Mar 20 at 18:05 Rafiq KhanRafiq Khan 1 2 |1 Answer
Reset to default 0step 1:
delete pubspec.lock file
and run flutter clean
step 2:
run dart pub cache clean or flutter pub cache clean
step 3:
run flutter pub get
and run the app
flutter doctor
? Also, performflutter clean
. – DevQt Commented Mar 21 at 13:48