C:\flutter\bin\flutter.bat --no-color build apk

Building without sound null safety For more information see https://dart.dev/null-safety/unsound-null-safety

Running Gradle task 'assembleRelease'...
/C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_math_fork-0.3.3+1/lib/src/widgets/selectable.dart:407:7: Error: The non-abstract class 'InternalSelectableMathState' is missing implementations for these members:

  • TextInputClient.insertTextPlaceholder
  • TextInputClient.removeTextPlaceholder
  • TextSelectionDelegate.copySelection
  • TextSelectionDelegate.cutSelection
  • TextSelectionDelegate.pasteText
  • TextSelectionDelegate.selectAll Try to either
  • provide an implementation,
  • inherit an implementation from a superclass or mixin,
  • mark the class as abstract, or
  • provide a 'noSuchMethod' implementation.

class InternalSelectableMathState extends State ^^^^^^^^^^^^^^^^^^^^^^^^^^^ /C:/flutter/packages/flutter/lib/src/services/text_input.dart:1124:8: Context: 'TextInputClient.insertTextPlaceholder' is defined here. void insertTextPlaceholder(Size size) {} ^^^^^^^^^^^^^^^^^^^^^ /C:/flutter/packages/flutter/lib/src/services/text_input.dart:1127:8: Context: 'TextInputClient.removeTextPlaceholder' is defined here. void removeTextPlaceholder() {} ^^^^^^^^^^^^^^^^^^^^^ /C:/flutter/packages/flutter/lib/src/services/text_input.dart:1041:8: Context: 'TextSelectionDelegate.copySelection' is defined here. void copySelection(SelectionChangedCause cause); ^^^^^^^^^^^^^ /C:/flutter/packages/flutter/lib/src/services/text_input.dart:1021:8: Context: 'TextSelectionDelegate.cutSelection' is defined here. void cutSelection(SelectionChangedCause cause); ^^^^^^^^^^^^ /C:/flutter/packages/flutter/lib/src/services/text_input.dart:1029:16: Context: 'TextSelectionDelegate.pasteText' is defined here. Future pasteText(SelectionChangedCause cause); ^^^^^^^^^ /C:/flutter/packages/flutter/lib/src/services/text_input.dart:1035:8: Context: 'TextSelectionDelegate.selectAll' is defined here. void selectAll(SelectionChangedCause cause); ^^^^^^^^^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/shared_value-1.1.1/lib/manager_widget.dart:28:26: Warning: Operand of null-aware operation '?.' has type 'SchedulerBinding' which excludes null.

  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). if (SchedulerBinding.instance?.schedulerPhase != SchedulerPhase.idle) { ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/shared_value-1.1.1/lib/manager_widget.dart:30:30: Warning: Operand of null-aware operation '?.' has type 'SchedulerBinding' which excludes null.
  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). await SchedulerBinding.instance?.endOfFrame; ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/dropdown_search-0.6.3/lib/dropdown_search.dart:357:26: Warning: Operand of null-aware operation '!' has type 'WidgetsBinding' which excludes null.
  • 'WidgetsBinding' is from 'package:flutter/src/widgets/binding.dart' ('/C:/flutter/packages/flutter/lib/src/widgets/binding.dart'). WidgetsBinding.instance!.addPostFrameCallback((_) { ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/provider-5.0.0/lib/src/inherited_provider.dart:391:26: Warning: Operand of null-aware operation '!' has type 'SchedulerBinding' which excludes null.
  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). SchedulerBinding.instance!.addPostFrameCallback((_) { ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/intl_phone_number_input-0.7.0+2/lib/src/widgets/input_widget.dart:321:20: Warning: Operand of null-aware operation '!' has type 'WidgetsBinding' which excludes null.
  • 'WidgetsBinding' is from 'package:flutter/src/widgets/binding.dart' ('/C:/flutter/packages/flutter/lib/src/widgets/binding.dart'). WidgetsBinding.instance!.addPostFrameCallback((timeStamp) { ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_auth_buttons-0.10.0/lib/src/button.dart:56:18: Error: The method 'RaisedButton' isn't defined for the class 'StretchableButton'.
  • 'StretchableButton' is from 'package:flutter_auth_buttons/src/button.dart' ('/C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_auth_buttons-0.10.0/lib/src/button.dart'). Try correcting the name to the name of an existing method, or defining a method named 'RaisedButton'. child: RaisedButton( ^^^^^^^^^^^^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_math_fork-0.3.3+1/lib/src/widgets/selectable.dart:459:24: Warning: Operand of null-aware operation '!' has type 'SchedulerBinding' which excludes null.
  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). SchedulerBinding.instance!.addPostFrameCallback((_) { ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_math_fork-0.3.3+1/lib/src/widgets/selection/overlay_manager.dart:138:28: Warning: Operand of null-aware operation '!' has type 'SchedulerBinding' which excludes null.
  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). if (SchedulerBinding.instance!.schedulerPhase == ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_math_fork-0.3.3+1/lib/src/widgets/selection/overlay_manager.dart:140:26: Warning: Operand of null-aware operation '!' has type 'SchedulerBinding' which excludes null.
  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). SchedulerBinding.instance! ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_math_fork-0.3.3+1/lib/src/widgets/selection/web_selection_manager.dart:119:24: Warning: Operand of null-aware operation '!' has type 'SchedulerBinding' which excludes null.
  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). SchedulerBinding.instance! ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_math_fork-0.3.3+1/lib/src/widgets/selection/overlay.dart:141:26: Warning: Operand of null-aware operation '!' has type 'SchedulerBinding' which excludes null.
  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). if (SchedulerBinding.instance!.schedulerPhase == ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_math_fork-0.3.3+1/lib/src/widgets/selection/overlay.dart:143:24: Warning: Operand of null-aware operation '!' has type 'SchedulerBinding' which excludes null.
  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). SchedulerBinding.instance!.addPostFrameCallback(_markNeedsBuild); ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_math_fork-0.3.3+1/lib/src/widgets/selection/overlay.dart:193:26: Warning: Operand of null-aware operation '!' has type 'SchedulerBinding' which excludes null.
  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). if (SchedulerBinding.instance!.schedulerPhase == ^ /C:/Users/Petra/AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_math_fork-0.3.3+1/lib/src/widgets/selection/overlay.dart:195:24: Warning: Operand of null-aware operation '!' has type 'SchedulerBinding' which excludes null.
  • 'SchedulerBinding' is from 'package:flutter/src/scheduler/binding.dart' ('/C:/flutter/packages/flutter/lib/src/scheduler/binding.dart'). SchedulerBinding.instance!.addPostFrameCallback(_markNeedsBuild); ^

FAILURE: Build failed with an exception.

  • Where: Script 'C:\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1156

  • What went wrong: Execution failed for task ':app:compileFlutterBuildRelease'.

Process 'command 'C:\flutter\bin\flutter.bat'' finished with non-zero exit value 1

1

There are 1 best solutions below

0
On

In my case, the issue was related with flutter_html: 2.1.5 which depends on flutter_math_fork-0.3.3+1 . Fixing the version of flutter_html to 3.0.0-alpha.2 (a newer version will probably work in the future) solved my problem.