While running my flutter app, it works fine but after sometimes I'm getting the error below:
the Dart compiler exited unexpectedly.
#0 throwToolExit (package:flutter_tools/src/base/common.dart:14:3)
#1 DefaultResidentCompiler._compile.<anonymous closure> (package:flutter_tools/src/compile.dart:771:13)
#2 _rootRun (dart:async/zone.dart:1180:38)
#3 _CustomZone.run (dart:async/zone.dart:1077:19)
#4 _CustomZone.runGuarded (dart:async/zone.dart:979:7)
#5 _BufferingStreamSubscription._sendDone.sendDone (dart:async/stream_impl.dart:392:13)
#6 _BufferingStreamSubscription._sendDone (dart:async/stream_impl.dart:402:15)
#7 _BufferingStreamSubscription._close (dart:async/stream_impl.dart:286:7)
#8 _SinkTransformerStreamSubscription._close (dart:async/stream_transformers.dart:98:11)
#9 _EventSinkWrapper.close (dart:async/stream_transformers.dart:25:11)
#10 _StringAdapterSink.close (dart:convert/string_conversion.dart:251:11)
#11 _LineSplitterSink.close (dart:convert/line_splitter.dart:136:11)
#12 _SinkTransformerStreamSubscription._handleDone (dart:async/stream_transformers.dart:143:24)
#13 _rootRun (dart:async/zone.dart:1180:38)
#14 _CustomZone.run (dart:async/zone.dart:1077:19)
#15 _CustomZone.runGuarded (dart:async/zone.dart:979:7)
#16 _BufferingStreamSubscription._sendDone.sendDone (dart:async/stream_impl.dart:392:13)
#17 _BufferingStreamSubscription._sendDone (dart:async/stream_impl.dart:402:15)
#18 _BufferingStreamSubscription._close (dart:async/stream_impl.dart:286:7)
#19 _SinkTransformerStreamSubscription._close (dart:async/stream_transformers.dart:98:11)
#20 _EventSinkWrapper.close (dart:async/stream_transformers.dart:25:11)
#21 _StringAdapterSink.close (dart:convert/string_conversion.dart:251:11)
#22 _Utf8ConversionSink.close (dart:convert/string_conversion.dart:302:20)
#23 _ConverterStreamEventSink.close (dart:convert/chunked_conversion.dart:83:18)
#24 _SinkTransformerStreamSubscription._handleDone (dart:async/stream_transformers.dart:143:24)
#25 _rootRun (dart:async/zone.dart:1180:38)
#26 _CustomZone.run (dart:async/zone.dart:1077:19)
#27 _CustomZone.runGuarded (dart:async/zone.dart:979:7)
#28 _BufferingStreamSubscription._sendDone.sendDone (dart:async/stream_impl.dart:392:13)
#29 _BufferingStreamSubscription._sendDone (dart:async/stream_impl.dart:402:15)
#30 _BufferingStreamSubscription._close (dart:async/stream_impl.dart:286:7)
#31 _SyncStreamControllerDispatch._sendDone (dart:async/stream_controller.dart:787:19)
#32 _StreamController._closeUnchecked (dart:async/stream_controller.dart:644:7)
#33 _StreamController.close (dart:async/stream_controller.dart:637:5)
#34 _Socket._onData (dart:io-patch/socket_patch.dart:1989:21)
#35 _rootRunUnary (dart:async/zone.dart:1196:13)
#36 _CustomZone.runUnary (dart:async/zone.dart:1085:19)
#37 _CustomZone.runUnaryGuarded (dart:async/zone.dart:987:7)
#38 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:339:11)
#39 _BufferingStreamSubscription._add (dart:async/stream_impl.dart:266:7)
#40 _SyncStreamControllerDispatch._sendData (dart:async/stream_controller.dart:779:19)
#41 _StreamController._add (dart:async/stream_controller.dart:655:7)
#42 _StreamController.add (dart:async/stream_controller.dart:597:5)
#43 new _RawSocket.<anonymous closure> (dart:io-patch/socket_patch.dart:1534:35)
#44 _NativeSocket.issueReadEvent.issue (dart:io-patch/socket_patch.dart:1012:18)
#45 _microtaskLoop (dart:async/schedule_microtask.dart:43:21)
#46 _startMicrotaskLoop (dart:async/schedule_microtask.dart:52:5)
#47 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:118:13)
#48 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:169:5)
[{"event":"app.stop","params":{"appId":"68806365-e542-4635-9e22-33f15caa4633"}}]
Flutter doctor: Doctor no issues found
classpath 'com.android.tools.build:gradle:3.6.2'
classpath 'com.google.gms:google-services:4.3.3'
Anyone knows how to solve this? Help please.
I had the following error and the only way I fixed it was by just doing as follows:
flutter clean
Related
I am tring to install and setup flutter by followig way
1. I downloaded flutter and unzip
2. Added path of flutter and bin folder in environment variable
3. Fire command flutter doctor
Then dart has been downloaded via command line and then i got error
Oops; flutter has exited unexpectedly: "Invalid argument(s): Cannot find executable for where.". Unable to generate crash report due to secondary error: Invalid argument(s): Cannot find executable for where.
please let us know at https://github.com/flutter/flutter/issues. Unhandled exception: ProcessExit: 1 #0 _handleToolError (package:flutter_tools/runner.dart:149:7) #1 _asyncErrorWrapperHelper.errorCallback (dart:async-patch/async_patch.dart:87:64) #2 _rootRunBinary (dart:async/zone.dart:1204:38) #3 _CustomZone.runBinary (dart:async/zone.dart:1093:19) #4 _FutureListener.handleError (dart:async/future_impl.dart:155:20) #5 Future._propagateToListeners.handleError (dart:async/future_impl.dart:694:47) #6 Future._propagateToListeners (dart:async/future_impl.dart:715:24) #7 Future._completeError (dart:async/future_impl.dart:534:5) #8 _AsyncAwaitCompleter.completeError (dart:async-patch/async_patch.dart:43:15) #9 _informUserOfCrash (package:flutter_tools/runner.dart) #10 _asyncErrorWrapperHelper.errorCallback (dart:async-patch/async_patch.dart:87:64) #11 _rootRunBinary (dart:async/zone.dart:1204:38) #12 _CustomZone.runBinary (dart:async/zone.dart:1093:19) #13 _FutureListener.handleError (dart:async/future_impl.dart:155:20) #14 Future._propagateToListeners.handleError (dart:async/future_impl.dart:694:47) #15 Future._propagateToListeners (dart:async/future_impl.dart:715:24) #16 Future._completeError (dart:async/future_impl.dart:534:5) #17 _AsyncAwaitCompleter.completeError (dart:async-patch/async_patch.dart:43:15) #18 _doctorText (package:flutter_tools/runner.dart) #19 _asyncErrorWrapperHelper.errorCallback (dart:async-patch/async_patch.dart:87:64) #20 _rootRunBinary (dart:async/zone.dart:1204:38) #21 _CustomZone.runBinary (dart:async/zone.dart:1093:19) #22 _FutureListener.handleError (dart:async/future_impl.dart:155:20) #23 Future._propagateToListeners.handleError (dart:async/future_impl.dart:694:47) #24 Future._propagateToListeners (dart:async/future_impl.dart:715:24) #25 Future._completeError (dart:async/future_impl.dart:534:5) #26 _AsyncAwaitCompleter.completeError (dart:async-patch/async_patch.dart:43:15) #27 AppContext.run (package:flutter_tools/src/base/context.dart) #28 _asyncErrorWrapperHelper.errorCallback (dart:async-patch/async_patch.dart:87:64) #29 _rootRunBinary (dart:async/zone.dart:1204:38) #30 _CustomZone.runBinary (dart:async/zone.dart:1093:19) #31 _FutureListener.handleError (dart:async/future_impl.dart:155:20) #32 Future._propagateToListeners.handleError (dart:async/future_impl.dart:694:47) #33 Future._propagateToListeners (dart:async/future_impl.dart:715:24) #34 Future._completeError (dart:async/future_impl.dart:534:5) #35 _AsyncAwaitCompleter.completeError (dart:async-patch/async_patch.dart:43:15) #36 AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart) #37 _asyncErrorWrapperHelper.errorCallback (dart:async-patch/async_patch.dart:87:64) #38 _rootRunBinary (dart:async/zone.dart:1204:38) #39 _CustomZone.runBinary (dart:async/zone.dart:1093:19) #40 _FutureListener.handleError (dart:async/future_impl.dart:155:20) #41 Future._propagateToListeners.handleError (dart:async/future_impl.dart:694:47) #42 Future._propagateToListeners (dart:async/future_impl.dart:715:24) #43 Future._completeError (dart:async/future_impl.dart:534:5) #44 Future._asyncCompleteError.<anonymous closure> (dart:async/future_impl.dart:582:7) #45 _rootRun (dart:async/zone.dart:1184:13) #46 _CustomZone.run (dart:async/zone.dart:1077:19) #47 _CustomZone.bindCallback.<anonymous closure> (dart:async/zone.dart:1003:23) #48 _microtaskLoop (dart:async/schedule_microtask.dart:43:21) #49 _startMicrotaskLoop (dart:async/schedule_microtask.dart:52:5) #50 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:118:13) #51 _Timer._runTimers (dart:isolate-patch/timer_impl.dart:405:11) #52 _Timer._handleMessage (dart:isolate-patch/timer_impl.dart:429:5) #53 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:168:12)
I solved the issue by following 3 steps,
first step:- you need to disabled your virus guard,
second step:- you should remove cache folder entirely (it is located in ex:- 'C:\flutter\bin\cache')
Run 'Flutter Doctor' which would download all artifacts again
You have to install git and then restart your editors and your device
I want to run my existing flutter app on windows, so I loaded the lastest flutter-desktop-embedding version, placed my code inside and tried to run it. It soon breaks with an exception:
Build process failed. To view the stack trace, please run `flutter run -d windows -v`.
#0 throwToolExit (package:flutter_tools/src/base/common.dart:28:3)
#1 buildWindows (package:flutter_tools/src/windows/build_windows.dart:82:5)
<asynchronous suspension>
#2 WindowsDevice.buildForDevice (package:flutter_tools/src/windows/windows_device.dart:46:11)
#3 DesktopDevice.startApp (package:flutter_tools/src/desktop_device.dart:87:13)
<asynchronous suspension>
#4 FlutterDevice.runHot (package:flutter_tools/src/resident_runner.dart:416:54)
<asynchronous suspension>
#5 HotRunner.run (package:flutter_tools/src/run_hot.dart:266:39)
<asynchronous suspension>
#6 RunCommand.runCommand (package:flutter_tools/src/commands/run.dart:499:37)
<asynchronous suspension>
#7 FlutterCommand.verifyThenRunCommand (package:flutter_tools/src/runner/flutter_command.dart:570:18)
#8 _asyncThenWrapperHelper.<anonymous closure> (dart:async-patch/async_patch.dart:71:64)
#9 _rootRunUnary (dart:async/zone.dart:1132:38)
#10 _CustomZone.runUnary (dart:async/zone.dart:1029:19)
#11 _FutureListener.handleValue (dart:async/future_impl.dart:137:18)
#12 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:678:45)
#13 Future._propagateToListeners (dart:async/future_impl.dart:707:32)
#14 Future._completeWithValue (dart:async/future_impl.dart:522:5)
#15 _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:30:15)
#16 _completeOnAsyncReturn (dart:async-patch/async_patch.dart:288:13)
#17 RunCommand.usageValues (package:flutter_tools/src/commands/run.dart)
#18 _asyncThenWrapperHelper.<anonymous closure> (dart:async-patch/async_patch.dart:71:64)
#19 _rootRunUnary (dart:async/zone.dart:1132:38)
#20 _CustomZone.runUnary (dart:async/zone.dart:1029:19)
#21 _FutureListener.handleValue (dart:async/future_impl.dart:137:18)
#22 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:678:45)
#23 Future._propagateToListeners (dart:async/future_impl.dart:707:32)
#24 Future._completeWithValue (dart:async/future_impl.dart:522:5)
#25 _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:30:15)
#26 _completeOnAsyncReturn (dart:async-patch/async_patch.dart:288:13)
#27 IosProject.isSwift (package:flutter_tools/src/project.dart)
#28 _asyncThenWrapperHelper.<anonymous closure> (dart:async-patch/async_patch.dart:71:64)
#29 _rootRunUnary (dart:async/zone.dart:1132:38)
#30 _CustomZone.runUnary (dart:async/zone.dart:1029:19)
#31 _FutureListener.handleValue (dart:async/future_impl.dart:137:18)
#32 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:678:45)
#33 Future._propagateToListeners (dart:async/future_impl.dart:707:32)
#34 Future._completeWithValue (dart:async/future_impl.dart:522:5)
#35 Future._asyncComplete.<anonymous closure> (dart:async/future_impl.dart:552:7)
#36 _rootRun (dart:async/zone.dart:1124:13)
#37 _CustomZone.run (dart:async/zone.dart:1021:19)
#38 _CustomZone.runGuarded (dart:async/zone.dart:923:7)
#39 _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:963:23)
#40 _microtaskLoop (dart:async/schedule_microtask.dart:41:21)
#41 _startMicrotaskLoop (dart:async/schedule_microtask.dart:50:5)
#42 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:116:13)
#43 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:173:5)
I am developing on the master channel, already made flutter upgrade and else I think i did everything else I need to do. Running the example comming with flutter-desktop-embedding does not throw any exception, and it seems that if I copy my lib folder into the examples folder, the app will not build.
Does anyone face this issue too?
This problem is due Flutter Version to Solve it
Open Terminal and Write flutter upgrade --force
Open Your Windows Flutter Project and Write flutter run
From today, after updating the dependencies, when I build the app doing appbundle, crash (not making an apk)
I print the result with flutter build appbundle --verbose
Gradle build failed to produce an Android bundle package.
#0 throwToolExit (package:flutter_tools/src/base/common.dart:28:3)
#1 _buildGradleProjectV2 (package:flutter_tools/src/android/gradle.dart:780:7)
#2 _asyncThenWrapperHelper.<anonymous closure> (dart:async-patch/async_patch.dart:71:64)
#3 _rootRunUnary (dart:async/zone.dart:1132:38)
#4 _CustomZone.runUnary (dart:async/zone.dart:1029:19)
#5 _FutureListener.handleValue (dart:async/future_impl.dart:137:18)
#6 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:678:45)
#7 Future._propagateToListeners (dart:async/future_impl.dart:707:32)
#8 Future._completeWithValue (dart:async/future_impl.dart:522:5)
#9 _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:30:15)
#10 _completeOnAsyncReturn (dart:async-patch/async_patch.dart:288:13)
#11 runCommandAndStreamOutput (package:flutter_tools/src/base/process.dart)
#12 _asyncThenWrapperHelper.<anonymous closure> (dart:async-patch/async_patch.dart:71:64)
#13 _rootRunUnary (dart:async/zone.dart:1132:38)
#14 _CustomZone.runUnary (dart:async/zone.dart:1029:19)
#15 _FutureListener.handleValue (dart:async/future_impl.dart:137:18)
#16 Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:678:45)
#17 Future._propagateToListeners (dart:async/future_impl.dart:707:32)
#18 Future._completeWithValue (dart:async/future_impl.dart:522:5)
#19 Future._asyncComplete.<anonymous closure> (dart:async/future_impl.dart:552:7)
#20 _rootRun (dart:async/zone.dart:1124:13)
#21 _CustomZone.run (dart:async/zone.dart:1021:19)
#22 _CustomZone.runGuarded (dart:async/zone.dart:923:7)
#23 _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:963:23)
#24 _microtaskLoop (dart:async/schedule_microtask.dart:41:21)
#25 _startMicrotaskLoop (dart:async/schedule_microtask.dart:50:5)
#26 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:116:13)
#27 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:173:5)
Steps to Reproduce
follow https://flutter.dev/docs/get-started/install/windows
git clone -b stable https://github.com/flutter/flutter.git
updated my Edit environment variables
Logs
C:\Users\Win10>flutter doctor
CreateProcessW failed 193
CreateProcessW failed 193
CreateProcessW failed 193
Unhandled exception:
ProcessException: %1 is not a valid Win32 application.
Command: C:\Program Files\Git\cmd\git.EXE log -n 1 --pretty=format:%H
#0 _ProcessImpl._runAndWait (dart:io-patch/process_patch.dart:489:7)
#1 _runNonInteractiveProcessSync (dart:io-patch/process_patch.dart:634:18)
#2 Process.runSync (dart:io-patch/process_patch.dart:66:12)
#3 LocalProcessManager.runSync (package:process/src/interface/local_process_manager.dart:83:20)
#4 _runWithLoggingSync (package:flutter_tools/src/base/process.dart:343:48)
#5 runSync (package:flutter_tools/src/base/process.dart:315:10)
#6 _runGit (package:flutter_tools/src/version.dart:532:10)
#7 new FlutterVersion (package:flutter_tools/src/version.dart:23:26)
#8 runInContext.<anonymous closure> (package:flutter_tools/src/context_runner.dart:81:29)
#9 AppContext._generateIfNecessary.<anonymous closure> (package:flutter_tools/src/base/context.dart:99:41)
#10 __InternalLinkedHashMap&_HashVMBase&MapMixin&_LinkedHashMapMixin.putIfAbsent (dart:collection-patch/compact_hash.dart:281:23)
#11 AppContext._generateIfNecessary (package:flutter_tools/src/base/context.dart:87:20)
#12 AppContext.get (package:flutter_tools/src/base/context.dart:115:32)
#13 FlutterVersion.instance (package:flutter_tools/src/version.dart:183:49)
#14 new Usage (package:flutter_tools/src/usage.dart:60:58)
#15 runInContext.<anonymous closure> (package:flutter_tools/src/context_runner.dart:101:20)
#16 AppContext._generateIfNecessary.<anonymous closure> (package:flutter_tools/src/base/context.dart:99:41)
#17 __InternalLinkedHashMap&_HashVMBase&MapMixin&_LinkedHashMapMixin.putIfAbsent (dart:collection-patch/compact_hash.dart:281:23)
#18 AppContext._generateIfNecessary (package:flutter_tools/src/base/context.dart:87:20)
#19 AppContext.get (package:flutter_tools/src/base/context.dart:115:32)
#20 Usage.instance (package:flutter_tools/src/usage.dart:84:40)
#21 flutterUsage (package:flutter_tools/src/usage.dart:54:33)
#22 _handleToolError (package:flutter_tools/runner.dart:112:7)
<asynchronous suspension>
#23 run.<anonymous closure>.<anonymous closure> (package:flutter_tools/runner.dart:69:13)
<asynchronous suspension>
#24 _rootRunBinary (dart:async/zone.dart:1148:13)
#25 _CustomZone.runBinary (dart:async/zone.dart:1037:19)
#26 runZoned.<anonymous closure> (dart:async/zone.dart:1479:21)
#27 _CustomZone.handleUncaughtError (dart:async/zone.dart:1003:19)
#28 Future._propagateToListeners (dart:async/future_impl.dart:589:16)
#29 Future._completeError (dart:async/future_impl.dart:491:5)
#30 _SyncCompleter._completeError (dart:async/future_impl.dart:55:12)
#31 _Completer.completeError (dart:async/future_impl.dart:27:5)
#32 _AsyncAwaitCompleter.completeError (dart:async-patch/async_patch.dart:40:18)
#33 run.<anonymous closure>.<anonymous closure> (package:flutter_tools/runner.dart)
<asynchronous suspension>
#34 _rootRun (dart:async/zone.dart:1124:13)
#35 _CustomZone.run (dart:async/zone.dart:1021:19)
#36 _runZoned (dart:async/zone.dart:1516:10)
#37 runZoned (dart:async/zone.dart:1500:12)
#38 run.<anonymous closure> (package:flutter_tools/runner.dart:60:18)
<asynchronous suspension>
#39 AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:153:29)
<asynchronous suspension>
#40 _rootRun (dart:async/zone.dart:1124:13)
#41 _CustomZone.run (dart:async/zone.dart:1021:19)
#42 _runZoned (dart:async/zone.dart:1516:10)
#43 runZoned (dart:async/zone.dart:1463:12)
#44 AppContext.run (package:flutter_tools/src/base/context.dart:152:18)
<asynchronous suspension>
#45 runInContext (package:flutter_tools/src/context_runner.dart:56:24)
<asynchronous suspension>
#46 run (package:flutter_tools/runner.dart:51:10)
#47 main (package:flutter_tools/executable.dart:62:9)
<asynchronous suspension>
#48 main (file:///C:/src/flutter/packages/flutter_tools/bin/flutter_tools.dart:8:3)
#49 _startIsolate.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:299:32)
#50 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:172:12)
Found https://github.com/flutter/flutter/issues/19805#issuecomment-478306166 and Flutter with installation error for %1 is not a valid win32 application, but I have follow what those research say , but none of those help
It seems you have not pasted the PATH in Environment Variables Account.
You have to take the flutter(Extracted folder), and paste the path upto flutter/bin
in the Edit Path table.
then try running flutter doctor from the folder(in terminal) where you have your flutter folder
How can I resolve the problem as below ?
I run my application normally, it's run well.
But when I've set break point, then tried to perform debugging my code.
It always shows the error messages which do not come from my code, debugger is interrupted as well.
Unhandled exception:
NoSuchMethodError: The getter 'cls' was called on null.
Receiver: null
Tried calling: cls
#0 Object.noSuchMethod (dart:core-patch/object_patch.dart:50:5)
#1 BodyBuilder.lookupInstanceMember (package:front_end/src/fasta/kernel/body_builder.dart:1604:30)
#2 BodyBuilder.scopeLookup (package:front_end/src/fasta/kernel/body_builder.dart:1764:13)
#3 BodyBuilder.handleIdentifier (package:front_end/src/fasta/kernel/body_builder.dart:1700:12)
#4 Parser.ensureIdentifier (package:front_end/src/fasta/parser/parser.dart:2165:14)
#5 Parser.parseSend (package:front_end/src/fasta/parser/parser.dart:4932:32)
#6 Parser.parseSendOrFunctionLiteral (package:front_end/src/fasta/parser/parser.dart:4675:12)
#7 Parser.parsePrimary (package:front_end/src/fasta/parser/parser.dart:4233:14)
#8 Parser.parseUnaryExpression (package:front_end/src/fasta/parser/parser.dart:4172:12)
#9 Parser.parsePrecedenceExpression (package:front_end/src/fasta/parser/parser.dart:3961:13)
#10 Parser.parseExpression (package:front_end/src/fasta/parser/parser.dart:3933:13)
#11 BodyBuilder.parseSingleExpression (package:front_end/src/fasta/kernel/body_builder.dart:1111:20)
#12 SourceLoader.buildExpression (package:front_end/src/fasta/source/source_loader.dart:327:21)
#13 IncrementalCompiler.compileExpression. (package:front_end/src/fasta/incremental_compiler.dart:795:61)
#14 CompilerContext.runInContext..
(package:front_end/src/fasta/compiler_context.dart:122:46)
#15 new Future.sync (dart:async/future.dart:224:31)
#16 CompilerContext.runInContext. (package:front_end/src/fasta/compiler_context.dart:122:19)
#17 _rootRun (dart:async/zone.dart:1124:13)
#18 _CustomZone.run (dart:async/zone.dart:1021:19)
#19 _runZoned (dart:async/zone.dart:1516:10)
#20 runZoned (dart:async/zone.dart:1463:12)
#21 CompilerContext.runInContext (package:front_end/src/fasta/compiler_context.dart:121:12)
#22 IncrementalCompiler.compileExpression (package:front_end/src/fasta/incremental_compiler.dart:726:26)
#23 IncrementalCompiler.compileExpression (package:vm/incremental_compiler.dart:156:23)
#24 FrontendCompiler.compileExpression (package:vm/frontend_server.dart:527:44)
#25 _FlutterFrontendCompiler.compileExpression (package:frontend_server/server.dart:62:22)
#26 listenAndCompile. (package:vm/frontend_server.dart:812:20)
#27 _RootZone.runUnaryGuarded (dart:async/zone.dart:1314:10)
#28 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:336:11)
#29 _BufferingStreamSubscription._add (dart:async/stream_impl.dart:263:7)
#30 _SinkTransformerStreamSubscription._add (dart:async/stream_transformers.dart:68:11)
#31 _EventSinkWrapper.add (dart:async/stream_transformers.dart:15:11)
#32 _StringAdapterSink.add (dart:convert/string_conversion.dart:236:11)
#33 _LineSplitterSink._addLines (dart:convert/line_splitter.dart:150:13)
#34 _LineSplitterSink.addSlice (dart:convert/line_splitter.dart:125:5)
#35 StringConversionSinkMixin.add (dart:convert/string_conversion.dart:163:5)
#36 _SinkTransformerStreamSubscription._handleData (dart:async/stream_transformers.dart:120:24)
#37 _RootZone.runUnaryGuarded (dart:async/zone.dart:1314:10)
#38 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:336:11)
#39 _BufferingStreamSubscription._add (dart:async/stream_impl.dart:263:7)
#40 _SinkTransformerStreamSubscription._add (dart:async/stream_transformers.dart:68:11)
#41 _EventSinkWrapper.add (dart:async/stream_transformers.dart:15:11)
#42 _StringAdapterSink.add (dart:convert/string_conversion.dart:236:11)
#43 _StringAdapterSink.addSlice (dart:convert/string_conversion.dart:241:7)
#44 _Utf8ConversionSink.addSlice (dart:convert/string_conversion.dart:312:20)
#45 _Utf8ConversionSink.add (dart:convert/string_conversion.dart:305:5)
#46 _ConverterStreamEventSink.add (dart:convert/chunked_conversion.dart:72:18)
#47 _SinkTransformerStreamSubscription._handleData (dart:async/stream_transformers.dart:120:24)
#48 _RootZone.runUnaryGuarded (dart:async/zone.dart:1314:10)
#49 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:336:11)
#50 _BufferingStreamSubscription._add (dart:async/stream_impl.dart:263:7)
#51 _SyncStreamController._sendData (dart:async/stream_controller.dart:764:19)
#52 _StreamController._add (dart:async/stream_controller.dart:640:7)
#53 _StreamController.add (dart:async/stream_controller.dart:586:5)
#54 _Socket._onData (dart:io-patch/socket_patch.dart:1786:41)
#55 _RootZone.runUnaryGuarded (dart:async/zone.dart:1314:10)
#56 _BufferingStreamSubscription._sendData (dart:async/stream_impl.dart:336:11)
#57 _BufferingStreamSubscription._add (dart:async/stream_impl.dart:263:7)
#58 _SyncStreamController._sendData (dart:async/stream_controller.dart:764:19)
#59 _StreamController._add (dart:async/stream_controller.dart:640:7)
#60 _StreamController.add (dart:async/stream_controller.dart:586:5)
#61 new _RawSocket. (dart:io-patch/socket_patch.dart:1335:33)
#62 _NativeSocket.issueReadEvent.issue (dart:io-patch/socket_patch.dart:856:14)
#63 _microtaskLoop (dart:async/schedule_microtask.dart:41:21)
#64 _startMicrotaskLoop (dart:async/schedule_microtask.dart:50:5)
#65 _runPendingImmediateCallback (dart:isolate-patch/isolate_patch.dart:116:13)
#66 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:173:5)
My code:
main.dart
void main() async {
Flame.images.loadAll(<String>[
'level0.jpg'
]);
Util flameUtil = Util();
await flameUtil.fullScreen();
await flameUtil.setOrientation(DeviceOrientation.portraitUp);
MyGame game = MyGame ();
runApp(game.widget);
....
mygame.dart:
......
MyGame() {
sprite = Sprite('level0.jpg');// Break point
}
.............
note:
I am using Android studio 3.1
flutter veriosn 1.7.8
channel stable
Thanks a lot!!!