Skip to content

Exception thrown when executing hot reload after making compilation-successful changes following update to Flutter 3.19.0 #143689

Description

@chocoyama

Steps to reproduce

  1. Launch the application once. (Flutter3.19.0, Dart3.3.0)
  2. Make a change to the code that does not affect execution.
  3. Execute Hot Reload.
  4. An exception is thrown.

Expected results

The modified code should be reflected in the application without any exceptions.

Actual results

The following exception is thrown:

Unhandled exception:
Crash when compiling:
Null check operator used on a null value

#0      _TypeBuilderComputerHelper.visitStructuralParameterType (package:front_end/src/fasta/kernel/type_builder_computer.dart:242)
#1      StructuralParameterType.accept1 (package:kernel/ast.dart:12766)
#2      _TypeBuilderComputerHelper.visitFunctionType (package:front_end/src/fasta/kernel/type_builder_computer.dart:169)
#3      FunctionType.accept1 (package:kernel/ast.dart:11598)
#4      _TypeBuilderComputerHelper.visit (package:front_end/src/fasta/kernel/type_builder_computer.dart:77)
#5      TypeBuilderComputer.visit (package:front_end/src/fasta/kernel/type_builder_computer.dart:37)
#6      DillLoader.computeTypeBuilder (package:front_end/src/fasta/dill/dill_loader.dart:353)
#7      DillTypeAliasBuilder.type (package:front_end/src/fasta/dill/dill_type_alias_builder.dart:61)
#8      SourceTypeAliasBuilder._checkCyclicTypedefDependency (package:front_end/src/fasta/source/source_type_alias_builder.dart:154)
#9      SourceTypeAliasBuilder._checkCyclicTypedefDependency (package:front_end/src/fasta/source/source_type_alias_builder.dart:216)
#10     SourceTypeAliasBuilder._checkCyclicTypedefDependency (package:front_end/src/fasta/source/source_type_alias_builder.dart:245)
#11     SourceTypeAliasBuilder.build (package:front_end/src/fasta/source/source_type_alias_builder.dart:91)
#12     SourceLibraryBuilder._buildOutlineNodes (package:front_end/src/fasta/source/source_library_builder.dart:3666)
#13     SourceLibraryBuilder.buildOutlineNodes (package:front_end/src/fasta/source/source_library_builder.dart:1149)
#14     SourceLoader.buildOutlineNodes (package:front_end/src/fasta/source/source_loader.dart:2583)
#15     KernelTarget.buildOutlines.<anonymous closure> (package:front_end/src/fasta/kernel/kernel_target.dart:446)
<asynchronous suspension>
#16     withCrashReporting (package:front_end/src/fasta/crash.dart:133)
<asynchronous suspension>
#17     KernelTarget.buildOutlines (package:front_end/src/fasta/kernel/kernel_target.dart:385)
<asynchronous suspension>
#18     IncrementalCompiler.computeDelta.<anonymous closure> (package:front_end/src/fasta/incremental_compiler.dart:366)
<asynchronous suspension>
#19     CompilerContext.clear (package:front_end/src/fasta/compiler_context.dart:139)
<asynchronous suspension>
#20     IncrementalCompiler.compile (package:vm/incremental_compiler.dart:77)
<asynchronous suspension>
#21     FrontendCompiler.recompileDelta (package:frontend_server/frontend_server.dart:943)
<asynchronous suspension>
#22     listenAndCompile.<anonymous closure> (package:frontend_server/frontend_server.dart:1381)
<asynchronous suspension>
the Dart compiler exited unexpectedly.

Code sample

There are no particular differences in the code.

Screenshots or Video

No response

Logs

No response

Flutter Doctor output

Doctor output
[✓] Flutter (Channel stable, 3.19.0, on macOS 14.2.1 23C71 darwin-arm64, locale ja-JP)
    • Flutter version 3.19.0 on channel stable at /Users/chocoyama/fvm/versions/3.19.0
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision bae5e49bc2 (5 days ago), 2024-02-13 17:46:18 -0800
    • Engine revision 04817c99c9
    • Dart version 3.3.0
    • DevTools version 2.31.1

[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/chocoyama/Library/Android/sdk
    • Platform android-34, build-tools 34.0.0
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.7+0-17.0.7b1000.6-10550314)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.2)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15C500b
    • CocoaPods version 1.14.3

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2023.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.7+0-17.0.7b1000.6-10550314)

[✓] VS Code (version 1.86.0)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.82.0

[✓] Connected device (3 available)
    • iPhone 15 Pro (mobile) • 5F0DE4FA-41E8-4390-A657-28DC4C75DA8D • ios            • com.apple.CoreSimulator.SimRuntime.iOS-17-2 (simulator)
    • macOS (desktop)        • macos                                • darwin-arm64   • macOS 14.2.1 23C71 darwin-arm64
    • Chrome (web)           • chrome                               • web-javascript • Google Chrome 121.0.6167.184
    ! Error: Browsing on the local area network for TakuyaのiPhone. Ensure the device is unlocked and attached with a cable or associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)

[✓] Network resources
    • All expected network resources are available.

• No issues found!

Metadata

Metadata

Labels

in triagePresently being triaged by the triage teamwaiting for responseThe Flutter team cannot make further progress on this issue until the original reporter responds

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions