Flutter Web 错误 - 在调度程序回调期间抛出以下 UnimplementedError

Big*_*ong 6 flutter flutter-web

我最近尝试构建我的 flutter 应用程序的网络版本。这是我第一次这样做。经过许多挑战和错误,所有问题都通过各种堆栈帖子解决,这是我当前面临的错误:

\n
Error: \xe2\x95\x90\xe2\x95\x90\xe2\x95\xa1 EXCEPTION CAUGHT BY SCHEDULER LIBRARY \xe2\x95\x9e\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\nThe following UnimplementedError was thrown during a scheduler\ncallback:\nUnimplementedError\n\nWhen the exception was thrown, this was the stack:\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart 216:49  throw_\nC:/b/s/w/ir/cache/builder/src/out/host_debug/flutter_web_sdk/lib/_engine/engine/html/scene_builder.dart 231:5              pushShaderMask\npackages/flutter/src/rendering/layer.dart 1812:26                                                                          addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1013:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1164:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1164:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1999:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1164:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1164:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1609:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 765:5                                                                            buildScene\npackages/flutter/src/rendering/view.dart 231:30                                                                            compositeFrame\npackages/flutter/src/rendering/binding.dart 458:18                                                                         drawFrame\npackages/flutter/src/widgets/binding.dart 895:13                                                                           drawFrame\npackages/flutter/src/rendering/binding.dart 320:5                                                                          [_handlePersistentFrameCallback]\npackages/flutter/src/scheduler/binding.dart 1117:15                                                                        [_invokeFrameCallback]\npackages/flutter/src/scheduler/binding.dart 1055:9                                                                         handleDrawFrame\npackages/flutter/src/scheduler/binding.dart 864:7                                                                          <fn>\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1182:47                                          _rootRun\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1093:19                                          run\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 997:7                                            runGuarded\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1037:23                                          <fn>\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1190:13                                          _rootRun\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1093:19                                          run\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1021:23                                          <fn>\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/_internal/js_dev_runtime/private/isolate_helper.dart 48:19       internalCallback\n\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\n\n    at Object.throw_ [as throw] (http://localhost:11342/dart_sdk.js:4348:11)\n    at http://localhost:11342/packages/Okuna/pages/auth/create_account/name_step.dart.lib.js:318203:21\n    at Generator.next (<anonymous>)\n    at runBody (http://localhost:11342/dart_sdk.js:37976:34)\n    at Object._async [as async] (http://localhost:11342/dart_sdk.js:38007:7)\n    at http://localhost:11342/packages/Okuna/pages/auth/create_account/name_step.dart.lib.js:318201:66\n    at Function.reportError (http://localhost:11342/packages/flutter/src/foundation/debug.dart.lib.js:3696:56)\n    at binding$5.WidgetsFlutterBinding.new.[_invokeFrameCallback] (http://localhost:11342/packages/flutter/src/scheduler/binding.dart.lib.js:771:35)\n    at binding$5.WidgetsFlutterBinding.new.handleDrawFrame (http://localhost:11342/packages/flutter/src/scheduler/binding.dart.lib.js:734:37)\n    at http://localhost:11342/packages/flutter/src/scheduler/binding.dart.lib.js:648:14\n    at _rootRun (http://localhost:11342/dart_sdk.js:38250:45)\n    at async._CustomZone.new.run (http://localhost:11342/dart_sdk.js:37426:14)\n    at async._CustomZone.new.runGuarded (http://localhost:11342/dart_sdk.js:37326:14)\n    at http://localhost:11342/dart_sdk.js:37380:33\n    at _rootRun (http://localhost:11342/dart_sdk.js:38256:14)\n    at async._CustomZone.new.run (http://localhost:11342/dart_sdk.js:37426:14)\n    at http://localhost:11342/dart_sdk.js:37365:33\n    at internalCallback (http://localhost:11342/dart_sdk.js:24100:11)\nError: \xe2\x95\x90\xe2\x95\x90\xe2\x95\xa1 EXCEPTION CAUGHT BY SERVICES LIBRARY \xe2\x95\x9e\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\nThe following MissingPluginException was thrown while activating\nplatform stream on channel uni_links/events:\nMissingPluginException(No implementation found for method listen\non channel uni_links/events)\n\nWhen the exception was thrown, this was the stack:\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart 216:49  throw_\npackages/flutter/src/services/platform_channel.dart 157:7                                                                  _invokeMethod\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/_internal/js_dev_runtime/patch/async_patch.dart 45:50            <fn>\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1198:47                                          _rootRunUnary\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1100:19                                          runUnary\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/future_impl.dart 143:18                                    handleValue\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/future_impl.dart 696:44                                    handleValueCallback\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/future_impl.dart 725:32                                    _propagateToListeners\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/future_impl.dart 529:5                                     [_completeWithValue]\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/future_impl.dart 567:7                                     <fn>\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1190:13                                          _rootRun\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1093:19                                          run\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/zone.dart 1021:23                                          callback\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/schedule_microtask.dart 41:11                              _microtaskLoop\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/async/schedule_microtask.dart 50:5                               _startMicrotaskLoop\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/_internal/js_dev_runtime/patch/async_patch.dart 166:15           <fn>\n\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\n\n    at Object.throw_ [as throw] (http://localhost:11342/dart_sdk.js:4348:11)\n    at http://localhost:11342/packages/Okuna/pages/auth/create_account/name_step.dart.lib.js:318203:21\n    at Generator.next (<anonymous>)\n    at runBody (http://localhost:11342/dart_sdk.js:37976:34)\n    at Object._async [as async] (http://localhost:11342/dart_sdk.js:38007:7)\n    at http://localhost:11342/packages/Okuna/pages/auth/create_account/name_step.dart.lib.js:318201:66\n    at Function.reportError (http://localhost:11342/packages/flutter/src/foundation/debug.dart.lib.js:3696:56)\n    at EventChannel.<anonymous> (http://localhost:11342/packages/flutter/src/services/system_channels.dart.lib.js:1153:39)\n    at Generator.throw (<anonymous>)\n    at http://localhost:11342/dart_sdk.js:37962:38\n    at _rootRunBinary (http://localhost:11342/dart_sdk.js:38278:45)\n    at async._CustomZone.new.runBinary (http://localhost:11342/dart_sdk.js:37440:14)\n    at _FutureListener.thenAwait.handleError (http://localhost:11342/dart_sdk.js:32783:48)\n    at handleError (http://localhost:11342/dart_sdk.js:33335:51)\n    at Function._propagateToListeners (http://localhost:11342/dart_sdk.js:33361:17)\n    at _Future.new.[_completeWithValue] (http://localhost:11342/dart_sdk.js:33199:23)\n    at http://localhost:11342/dart_sdk.js:33222:35\n    at _rootRun (http://localhost:11342/dart_sdk.js:38256:14)\n    at async._CustomZone.new.run (http://localhost:11342/dart_sdk.js:37426:14)\n    at async._AsyncCallbackEntry.new.callback (http://localhost:11342/dart_sdk.js:37365:33)\n    at Object._microtaskLoop (http://localhost:11342/dart_sdk.js:38071:13)\n    at _startMicrotaskLoop (http://localhost:11342/dart_sdk.js:38077:13)\n    at http://localhost:11342/dart_sdk.js:33574:9\nError: Unsupported operation: Platform._operatingSystem\n    at Object.throw_ [as throw] (http://localhost:11342/dart_sdk.js:4348:11)\n    at Function._operatingSystem (http://localhost:11342/dart_sdk.js:54995:17)\n    at Function.get operatingSystem [as operatingSystem] (http://localhost:11342/dart_sdk.js:55041:27)\n    at get _operatingSystem (http://localhost:11342/dart_sdk.js:54954:27)\n    at Function.desc.get [as _operatingSystem] (http://localhost:11342/dart_sdk.js:4842:17)\n    at get isIOS (http://localhost:11342/dart_sdk.js:54978:26)\n    at Function.desc.get [as isIOS] (http://localhost:11342/dart_sdk.js:4842:17)\n    at flutter_secure_storage.FlutterSecureStorage.new.[_selectOptions] (http://localhost:11342/packages/flutter_secure_storage/flutter_secure_storage.dart.lib.js:133:36)\n    at flutter_secure_storage.FlutterSecureStorage.new.delete (http://localhost:11342/packages/flutter_secure_storage/flutter_secure_storage.dart.lib.js:116:187)\n    at storage._SecureStore.new.remove (http://localhost:11342/packages/Okuna/services/storage.dart.lib.js:161:33)\n    at storage.OBStorage.new.remove (http://localhost:11342/packages/Okuna/services/storage.dart.lib.js:86:25)\n    at user$0.UserService.new._removeStoredUserData (http://localhost:11342/packages/Okuna/pages/auth/create_account/name_step.dart.lib.js:311436:28)\n    at _removeStoredUserData.next (<anonymous>)\n    at runBody (http://localhost:11342/dart_sdk.js:37976:34)\n    at Object._async [as async] (http://localhost:11342/dart_sdk.js:38007:7)\n    at user$0.UserService.new.[_removeStoredUserData] (http://localhost:11342/packages/Okuna/pages/auth/create_account/name_step.dart.lib.js:311435:20)\n    at user$0.UserService.new.logout (http://localhost:11342/packages/Okuna/pages/auth/create_account/name_step.dart.lib.js:309104:44)\n    at logout.throw (<anonymous>)\n    at http://localhost:11342/dart_sdk.js:37962:38\n    at _rootRunBinary (http://localhost:11342/dart_sdk.js:38278:45)\n    at async._CustomZone.new.runBinary (http://localhost:11342/dart_sdk.js:37440:14)\n    at _FutureListener.thenAwait.handleError (http://localhost:11342/dart_sdk.js:32783:48)\n    at handleError (http://localhost:11342/dart_sdk.js:33335:51)\n    at Function._propagateToListeners (http://localhost:11342/dart_sdk.js:33361:17)\n    at _Future.new.[_completeWithValue] (http://localhost:11342/dart_sdk.js:33199:23)\n    at http://localhost:11342/dart_sdk.js:33222:35\n    at _rootRun (http://localhost:11342/dart_sdk.js:38256:14)\n    at async._CustomZone.new.run (http://localhost:11342/dart_sdk.js:37426:14)\n    at async._AsyncCallbackEntry.new.callback (http://localhost:11342/dart_sdk.js:37365:33)\n    at Object._microtaskLoop (http://localhost:11342/dart_sdk.js:38071:13)\n    at _startMicrotaskLoop (http://localhost:11342/dart_sdk.js:38077:13)\n    at http://localhost:11342/dart_sdk.js:33574:9\nError: \xe2\x95\x90\xe2\x95\x90\xe2\x95\xa1 EXCEPTION CAUGHT BY SCHEDULER LIBRARY \xe2\x95\x9e\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\xe2\x95\x90\nThe following UnimplementedError was thrown during a scheduler\ncallback:\nUnimplementedError\n\nWhen the exception was thrown, this was the stack:\nC:/b/s/w/ir/cache/builder/src/out/host_debug/dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart 216:49  throw_\nC:/b/s/w/ir/cache/builder/src/out/host_debug/flutter_web_sdk/lib/_engine/engine/html/scene_builder.dart 231:5              pushShaderMask\npackages/flutter/src/rendering/layer.dart 1812:26                                                                          addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1013:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1164:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1164:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1999:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5                                                                            [_addToSceneWithRetainedRendering]\npackages/flutter/src/rendering/layer.dart 1027:14                                                                          addChildrenToScene\npackages/flutter/src/rendering/layer.dart 1164:5                                                                           addToScene\npackages/flutter/src/rendering/layer.dart 440:5             

vix*_*xez 6

截至撰写本文时,ShaderMask 在网络上不受支持。

您必须找出导致此问题的 Widget,并解决它或使用替代方案,直到实现此问题。

您可以关注GitHub 问题。