-
Notifications
You must be signed in to change notification settings - Fork 29.8k
Closed
Labels
a: first hourThe first hour of using FlutterThe first hour of using Flutterc: crashStack traces logged to the consoleStack traces logged to the consolec: regressionIt was better in the past than it is nowIt was better in the past than it is nowt: gradle"flutter build" and "flutter run" on Android"flutter build" and "flutter run" on AndroidtoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.
Description
flutter create compiler_crash- Replace lib/main.dart with:
import 'package:flutter/material.dart';
void main() => runApp(test: null);
- In the compiler_crash/ directory, run
flutter run.
Output:
$ flutter run
Launching lib/main.dart on Pixel 3 XL in debug mode...
Running Gradle task 'assembleDebug'...
Compiler message:
lib/main.dart:3:22: Error: Too few positional arguments: 1 required, 0 given.
void main() => runApp(test: null);
^
../flutter/packages/flutter/lib/src/widgets/binding.dart:867:6: Context: Found this candidate, but the arguments don't match.
void runApp(Widget app) {
^^^^^^
Target kernel_snapshot failed: Exception: Errors during snapshot creation: null
#0 KernelSnapshot.build (package:flutter_tools/src/build_system/targets/dart.dart:231:7)
<asynchronous suspension>
#1 _BuildInstance._invokeInternal (package:flutter_tools/src/build_system/build_system.dart:526:25)
<asynchronous suspension>
#2 _BuildInstance.invokeTarget.<anonymous closure> (package:flutter_tools/src/build_system/build_system.dart:481:35)
#3 new Future.sync (dart:async/future.dart:222:31)
#4 AsyncMemoizer.runOnce (package:async/src/async_memoizer.dart:43:45)
#5 _BuildInstance.invokeTarget (package:flutter_tools/src/build_system/build_system.dart:481:21)
<asynchronous suspension>
<asynchronous suspension>
#6 BuildSystem.build (package:flutter_tools/src/build_system/build_system.dart:419:36)
<asynchronous suspension>
#7 AssembleCommand.runCommand (package:flutter_tools/src/commands/assemble.dart:154:50)
<asynchronous suspension>
#8 FlutterCommand.verifyThenRunCommand (package:flutter_tools/src/runner/flutter_command.dart:607:18)
<asynchronous suspension>
#9 FlutterCommand.run.<anonymous closure> (package:flutter_tools/src/runner/flutter_command.dart:507:33)
<asynchronous suspension>
#10 AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:146:29)
<asynchronous suspension>
#11 _rootRun (dart:async/zone.dart:1124:13)
#12 _CustomZone.run (dart:async/zone.dart:1021:19)
#13 _runZoned (dart:async/zone.dart:1516:10)
#14 runZoned (dart:async/zone.dart:1463:12)
#15 AppContext.run (package:flutter_tools/src/base/context.dart:145:18)
<asynchronous suspension>
#16 FlutterCommand.run (package:flutter_tools/src/runner/flutter_command.dart:497:20)
#17 CommandRunner.runCommand (package:args/command_runner.dart:197:27)
<asynchronous suspension>
#18 FlutterCommandRunner.runCommand.<anonymous closure> (package:flutter_tools/src/runner/flutter_command_runner.dart:416:21)
<asynchronous suspension>
#19 AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:146:29)
<asynchronous suspension>
#20 _rootRun (dart:async/zone.dart:1124:13)
#21 _CustomZone.run (dart:async/zone.dart:1021:19)
#22 _runZoned (dart:async/zone.dart:1516:10)
#23 runZoned (dart:async/zone.dart:1463:12)
#24 AppContext.run (package:flutter_tools/src/base/context.dart:145:18)
<asynchronous suspension>
#25 FlutterCommandRunner.runCommand (package:flutter_tools/src/runner/flutter_command_runner.dart:367:19)
<asynchronous suspension>
#26 CommandRunner.run.<anonymous closure> (package:args/command_runner.dart:112:25)
#27 new Future.sync (dart:async/future.dart:222:31)
#28 CommandRunner.run (package:args/command_runner.dart:112:14)
#29 FlutterCommandRunner.run (package:flutter_tools/src/runner/flutter_command_runner.dart:251:18)
#30 run.<anonymous closure>.<anonymous closure> (package:flutter_tools/runner.dart:63:22)
<asynchronous suspension>
#31 _rootRun (dart:async/zone.dart:1124:13)
#32 _CustomZone.run (dart:async/zone.dart:1021:19)
#33 _runZoned (dart:async/zone.dart:1516:10)
#34 runZoned (dart:async/zone.dart:1500:12)
#35 run.<anonymous closure> (package:flutter_tools/runner.dart:61:18)
<asynchronous suspension>
#36 AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:146:29)
<asynchronous suspension>
#37 _rootRun (dart:async/zone.dart:1124:13)
#38 _CustomZone.run (dart:async/zone.dart:1021:19)
#39 _runZoned (dart:async/zone.dart:1516:10)
#40 runZoned (dart:async/zone.dart:1463:12)
#41 AppContext.run (package:flutter_tools/src/base/context.dart:145:18)
<asynchronous suspension>
#42 runInContext (package:flutter_tools/src/context_runner.dart:65:24)
<asynchronous suspension>
#43 run (package:flutter_tools/runner.dart:50:10)
#44 main (package:flutter_tools/executable.dart:65:9)
<asynchronous suspension>
#45 main (file:///usr/local/google/home/ianh/dev/flutter/packages/flutter_tools/bin/flutter_tools.dart:8:3)
#46 _startIsolate.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:303:32)
#47 _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:172:12)
build failed.
FAILURE: Build failed with an exception.
* Where:
Script '/usr/local/google/home/ianh/dev/flutter/packages/flutter_tools/gradle/flutter.gradle' line: 716
* What went wrong:
Execution failed for task ':app:compileFlutterBuildDebugArm64'.
> Process 'command '/usr/local/google/home/ianh/dev/flutter/bin/flutter'' 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 10s
Running Gradle task 'assembleDebug'... 11.2s
Gradle task assembleDebug failed with exit code 1
Metadata
Metadata
Assignees
Labels
a: first hourThe first hour of using FlutterThe first hour of using Flutterc: crashStack traces logged to the consoleStack traces logged to the consolec: regressionIt was better in the past than it is nowIt was better in the past than it is nowt: gradle"flutter build" and "flutter run" on Android"flutter build" and "flutter run" on AndroidtoolAffects the "flutter" command-line tool. See also t: labels.Affects the "flutter" command-line tool. See also t: labels.