amake / org_flutter

Org Mode widgets for Flutter
MIT License
17 stars 3 forks source link

Crash when start debuging on Windows: Null check operator used on a null value #10

Closed shelverizr closed 9 months ago

shelverizr commented 9 months ago

VSCode debug console output:

Flutter assets will be downloaded from https://storage.flutter-io.cn. Make sure you trust this source!

Launching lib\main.dart on Windows in debug mode...
Unhandled exception:
Crash when compiling file:///C:/Users/Administrator/AppData/Local/Pub/Cache/hosted/pub.flutter-io.cn/org_flutter-4.7.0/lib/src/controller.dart at character offset 16741:
Null check operator used on a null value

#0      BodyBuilder.buildConstructorInvocation.<anonymous closure> (package:front_end/src/fasta/kernel/body_builder.dart:6614)
#1      new _GrowableList.generate (dart:core-patch/growable_array.dart:136)
#2      BodyBuilder.buildConstructorInvocation (package:front_end/src/fasta/kernel/body_builder.dart:6612)
#3      TypeUseGenerator.doInvocation (package:front_end/src/fasta/kernel/expression_generator.dart:3464)
#4      BodyBuilder.finishSend (package:front_end/src/fasta/kernel/body_builder.dart:2465)
#5      BodyBuilder.handleSend (package:front_end/src/fasta/kernel/body_builder.dart:2445)
#6      Parser.parseSend (package:_fe_analyzer_shared/src/parser/parser_impl.dart:7547)
#7      Parser.parseSendOrFunctionLiteral (package:_fe_analyzer_shared/src/parser/parser_impl.dart:7069)
#8      Parser.parsePrimary (package:_fe_analyzer_shared/src/parser/parser_impl.dart:6450)
#9      Parser.parseUnaryExpression (package:_fe_analyzer_shared/src/parser/parser_impl.dart:6341)
#10     Parser.parsePrecedenceExpression (package:_fe_analyzer_shared/src/parser/parser_impl.dart:5784)
#11     Parser.parseExpression (package:_fe_analyzer_shared/src/parser/parser_impl.dart:5724)
#12     Parser.parseVariableInitializerOpt (package:_fe_analyzer_shared/src/parser/parser_impl.dart:3879)
#13     Parser.parseOptionallyInitializedIdentifier (package:_fe_analyzer_shared/src/parser/parser_impl.dart:8133)
#14     Parser.parseVariablesDeclarationRest (package:_fe_analyzer_shared/src/parser/parser_impl.dart:8114)
#15     Parser.parseExpressionStatementOrDeclarationAfterModifiers (package:_fe_analyzer_shared/src/parser/parser_impl.dart:8107)
#16     Parser.parseStatementX (package:_fe_analyzer_shared/src/parser/parser_impl.dart:5507)
#17     Parser.parseStatement (package:_fe_analyzer_shared/src/parser/parser_impl.dart:5476)
#18     Parser.parseFunctionBody (package:_fe_analyzer_shared/src/parser/parser_impl.dart:5381)
#19     DietListener.buildFunctionBody (package:front_end/src/fasta/source/diet_listener.dart:1232)
#20     DietListener._endClassMethod (package:front_end/src/fasta/source/diet_listener.dart:773)
#21     DietListener.endClassMethod (package:front_end/src/fasta/source/diet_listener.dart:698)
#22     Parser.parseMethod (package:_fe_analyzer_shared/src/parser/parser_impl.dart:4965)
#23     Parser.parseClassOrMixinOrExtensionOrEnumMemberImpl (package:_fe_analyzer_shared/src/parser/parser_impl.dart:4678)
#24     Parser.parseClassOrMixinOrExtensionBody (package:_fe_analyzer_shared/src/parser/parser_impl.dart:4295)
#25     Parser.parseClass (package:_fe_analyzer_shared/src/parser/parser_impl.dart:2663)
#26     Parser.parseClassOrNamedMixinApplication (package:_fe_analyzer_shared/src/parser/parser_impl.dart:2621)
#27     Parser._handleModifiersForClassDeclaration (package:_fe_analyzer_shared/src/parser/parser_impl.dart:819)
#28     Parser.parseTopLevelKeywordDeclaration (package:_fe_analyzer_shared/src/parser/parser_impl.dart:658)
#29     Parser.parseTopLevelDeclarationImpl (package:_fe_analyzer_shared/src/parser/parser_impl.dart:531)
#30     Parser.parseUnit (package:_fe_analyzer_shared/src/parser/parser_impl.dart:411)
#31     SourceLoader.buildBody (package:front_end/src/fasta/source/source_loader.dart:1244)
<asynchronous suspension>
#32     SourceLoader.buildBodies (package:front_end/src/fasta/source/source_loader.dart:666)
<asynchronous suspension>
#33     KernelTarget.buildComponent.<anonymous closure> (package:front_end/src/fasta/kernel/kernel_target.dart:595)
<asynchronous suspension>
#34     withCrashReporting (package:front_end/src/fasta/crash.dart:133)
<asynchronous suspension>
#35     KernelTarget.buildComponent (package:front_end/src/fasta/kernel/kernel_target.dart:576)
<asynchronous suspension>
#36     IncrementalCompiler.computeDelta.<anonymous closure> (package:front_end/src/fasta/incremental_compiler.dart:409)
<asynchronous suspension>
#37     CompilerContext.clear (package:front_end/src/fasta/compiler_context.dart:139)
<asynchronous suspension>
#38     IncrementalCompiler.compile (package:vm/incremental_compiler.dart:77)
<asynchronous suspension>
#39     FrontendCompiler.compile (package:frontend_server/frontend_server.dart:612)
<asynchronous suspension>
#40     listenAndCompile.<anonymous closure> (package:frontend_server/frontend_server.dart:1331)
<asynchronous suspension>
the Dart compiler exited unexpectedly.
the Dart compiler exited unexpectedly.

Exited (1).

main.dart:

import 'package:flutter/material.dart';
import 'package:org_flutter/org_flutter.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        // This is the theme of your application.
        //
        // TRY THIS: Try running your application with "flutter run". You'll see
        // the application has a purple toolbar. Then, without quitting the app,
        // try changing the seedColor in the colorScheme below to Colors.green
        // and then invoke "hot reload" (save your changes or press the "hot
        // reload" button in a Flutter-supported IDE, or press "r" if you used
        // the command line to start the app).
        //
        // Notice that the counter didn't reset back to zero; the application
        // state is not lost during the reload. To reset the state, use hot
        // restart instead.
        //
        // This works for code too, not just values: Most code changes can be
        // tested with just a hot reload.
        colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple),
        useMaterial3: true,
      ),
      home: const MyHomePage(title: 'Flutter Demo Home Page'),
    );
  }
}

class MyHomePage extends StatefulWidget {
  const MyHomePage({super.key, required this.title});

  // This widget is the home page of your application. It is stateful, meaning
  // that it has a State object (defined below) that contains fields that affect
  // how it looks.

  // This class is the configuration for the state. It holds the values (in this
  // case the title) provided by the parent (in this case the App widget) and
  // used by the build method of the State. Fields in a Widget subclass are
  // always marked "final".

  final String title;

  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  int _counter = 0;

  void _incrementCounter() {
    setState(() {
      // This call to setState tells the Flutter framework that something has
      // changed in this State, which causes it to rerun the build method below
      // so that the display can reflect the updated values. If we changed
      // _counter without calling setState(), then the build method would not be
      // called again, and so nothing would appear to happen.
      _counter++;
    });
  }

  @override
  Widget build(BuildContext context) {
    // This method is rerun every time setState is called, for instance as done
    // by the _incrementCounter method above.
    //
    // The Flutter framework has been optimized to make rerunning build methods
    // fast, so that you can just rebuild anything that needs updating rather
    // than having to individually change instances of widgets.
    return Scaffold(
      appBar: AppBar(
        // TRY THIS: Try changing the color here to a specific color (to
        // Colors.amber, perhaps?) and trigger a hot reload to see the AppBar
        // change color while the other colors stay the same.
        backgroundColor: Theme.of(context).colorScheme.inversePrimary,
        // Here we take the value from the MyHomePage object that was created by
        // the App.build method, and use it to set our appbar title.
        title: Text(widget.title),
      ),
      body: Center(
        // Center is a layout widget. It takes a single child and positions it
        // in the middle of the parent.
        child: Column(
          // Column is also a layout widget. It takes a list of children and
          // arranges them vertically. By default, it sizes itself to fit its
          // children horizontally, and tries to be as tall as its parent.
          //
          // Column has various properties to control how it sizes itself and
          // how it positions its children. Here we use mainAxisAlignment to
          // center the children vertically; the main axis here is the vertical
          // axis because Columns are vertical (the cross axis would be
          // horizontal).
          //
          // TRY THIS: Invoke "debug painting" (choose the "Toggle Debug Paint"
          // action in the IDE, or press "p" in the console), to see the
          // wireframe for each widget.
          mainAxisAlignment: MainAxisAlignment.center,
          children: <Widget>[
            const Text(
              'You have pushed the button this many times:',
            ),
            Text(
              '$_counter',
              style: Theme.of(context).textTheme.headlineMedium,
            ),
            const Org('''* TODO [#A] foo bar
baz buzz''')
          ],
        ),
      ),
      floatingActionButton: FloatingActionButton(
        onPressed: _incrementCounter,
        tooltip: 'Increment',
        child: const Icon(Icons.add),
      ), // This trailing comma makes auto-formatting nicer for build methods.
    );
  }
}

pubspec.yaml:

name: test_sample
description: "A new Flutter project."
# The following line prevents the package from being accidentally published to
# pub.dev using `flutter pub publish`. This is preferred for private packages.
publish_to: 'none' # Remove this line if you wish to publish to pub.dev

# The following defines the version and build number for your application.
# A version number is three numbers separated by dots, like 1.2.43
# followed by an optional build number separated by a +.
# Both the version and the builder number may be overridden in flutter
# build by specifying --build-name and --build-number, respectively.
# In Android, build-name is used as versionName while build-number used as versionCode.
# Read more about Android versioning at https://developer.android.com/studio/publish/versioning
# In iOS, build-name is used as CFBundleShortVersionString while build-number is used as CFBundleVersion.
# Read more about iOS versioning at
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
# In Windows, build-name is used as the major, minor, and patch parts
# of the product and file versions while build-number is used as the build suffix.
version: 1.0.0+1

environment:
  sdk: '>=3.3.0-91.0.dev <4.0.0'

# Dependencies specify other packages that your package needs in order to work.
# To automatically upgrade your package dependencies to the latest versions
# consider running `flutter pub upgrade --major-versions`. Alternatively,
# dependencies can be manually updated by changing the version numbers below to
# the latest version available on pub.dev. To see which dependencies have newer
# versions available, run `flutter pub outdated`.
dependencies:
  flutter:
    sdk: flutter

  # The following adds the Cupertino Icons font to your application.
  # Use with the CupertinoIcons class for iOS style icons.
  cupertino_icons: ^1.0.2
  org_flutter: ^4.7.0

dev_dependencies:
  flutter_test:
    sdk: flutter

  # The "flutter_lints" package below contains a set of recommended lints to
  # encourage good coding practices. The lint set provided by the package is
  # activated in the `analysis_options.yaml` file located at the root of your
  # package. See that file for information about deactivating specific lint
  # rules and activating additional ones.
  flutter_lints: ^3.0.0

# For information on the generic Dart part of this file, see the
# following page: https://dart.dev/tools/pub/pubspec

# The following section is specific to Flutter packages.
flutter:

  # The following line ensures that the Material Icons font is
  # included with your application, so that you can use the icons in
  # the material Icons class.
  uses-material-design: true

  # To add assets to your application, add an assets section, like this:
  # assets:
  #   - images/a_dot_burr.jpeg
  #   - images/a_dot_ham.jpeg

  # An image asset can refer to one or more resolution-specific "variants", see
  # https://flutter.dev/assets-and-images/#resolution-aware

  # For details regarding adding assets from package dependencies, see
  # https://flutter.dev/assets-and-images/#from-packages

  # To add custom fonts to your application, add a fonts section here,
  # in this "flutter" section. Each entry in this list should have a
  # "family" key with the font family name, and a "fonts" key with a
  # list giving the asset and other descriptors for the font. For
  # example:
  # fonts:
  #   - family: Schyler
  #     fonts:
  #       - asset: fonts/Schyler-Regular.ttf
  #       - asset: fonts/Schyler-Italic.ttf
  #         style: italic
  #   - family: Trajan Pro
  #     fonts:
  #       - asset: fonts/TrajanPro.ttf
  #       - asset: fonts/TrajanPro_Bold.ttf
  #         weight: 700
  #
  # For details regarding fonts from package dependencies,
  # see https://flutter.dev/custom-fonts/#from-packages

pubspec.lock:

# Generated by pub
# See https://dart.dev/tools/pub/glossary#lockfile
packages:
  async:
    dependency: transitive
    description:
      name: async
      sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "2.11.0"
  boolean_selector:
    dependency: transitive
    description:
      name: boolean_selector
      sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "2.1.1"
  characters:
    dependency: transitive
    description:
      name: characters
      sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.3.0"
  clock:
    dependency: transitive
    description:
      name: clock
      sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.1.1"
  collection:
    dependency: transitive
    description:
      name: collection
      sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.18.0"
  crypto:
    dependency: transitive
    description:
      name: crypto
      sha256: ff625774173754681d66daaf4a448684fb04b78f902da9cb3d308c19cc5e8bab
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "3.0.3"
  cupertino_icons:
    dependency: "direct main"
    description:
      name: cupertino_icons
      sha256: d57953e10f9f8327ce64a508a355f0b1ec902193f66288e8cb5070e7c47eeb2d
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.0.6"
  equatable:
    dependency: transitive
    description:
      name: equatable
      sha256: c2b87cb7756efdf69892005af546c56c0b5037f54d2a88269b4f347a505e3ca2
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "2.0.5"
  fake_async:
    dependency: transitive
    description:
      name: fake_async
      sha256: "511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.3.1"
  flutter:
    dependency: "direct main"
    description: flutter
    source: sdk
    version: "0.0.0"
  flutter_lints:
    dependency: "direct dev"
    description:
      name: flutter_lints
      sha256: e2a421b7e59244faef694ba7b30562e489c2b489866e505074eb005cd7060db7
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "3.0.1"
  flutter_test:
    dependency: "direct dev"
    description: flutter
    source: sdk
    version: "0.0.0"
  flutter_tex_js:
    dependency: transitive
    description:
      name: flutter_tex_js
      sha256: "8e731a5c89a07a75d86c83a20fa8810c5f6ea88b34b3f05746b1f59416cb2622"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "3.0.0"
  flutter_tex_js_android:
    dependency: transitive
    description:
      name: flutter_tex_js_android
      sha256: "4905004dcce0de104e58bf09667f9484cc99c9ddeb3a2c142e690047d1ddb169"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "2.0.1"
  flutter_tex_js_ios:
    dependency: transitive
    description:
      name: flutter_tex_js_ios
      sha256: "5ce406e086b084c3a18b370ed3c0f5da5865afecad24a31649a217ca75e0fdbe"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "2.0.3"
  flutter_tex_js_platform_interface:
    dependency: transitive
    description:
      name: flutter_tex_js_platform_interface
      sha256: d6d4055233af0160170cb193b52f450f81e120fdb85045596dfc52f9f9b46e26
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.0.0"
  functional_zipper:
    dependency: transitive
    description:
      name: functional_zipper
      sha256: "1010a17991c1d1f9bffff65777abb34d39c5ce05bfe2203e18f395fc05296ad5"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "0.0.2"
  highlighting:
    dependency: transitive
    description:
      name: highlighting
      sha256: "196005ed9c98ee559939fcecd466fa941b9e99b3a93394691b86780ad4da50f3"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "0.9.0+11.8.0"
  intl:
    dependency: transitive
    description:
      name: intl
      sha256: "3bc132a9dbce73a7e4a21a17d06e1878839ffbf975568bc875c60537824b0c4d"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "0.18.1"
  leak_tracker:
    dependency: transitive
    description:
      name: leak_tracker
      sha256: "7e108028e3d258667d079986da8c0bc32da4cb57431c2af03b1dc1038621a9dc"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "9.0.13"
  leak_tracker_testing:
    dependency: transitive
    description:
      name: leak_tracker_testing
      sha256: b06739349ec2477e943055aea30172c5c7000225f79dad4702e2ec0eda79a6ff
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.0.5"
  lints:
    dependency: transitive
    description:
      name: lints
      sha256: cbf8d4b858bb0134ef3ef87841abdf8d63bfc255c266b7bf6b39daa1085c4290
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "3.0.0"
  matcher:
    dependency: transitive
    description:
      name: matcher
      sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "0.12.16"
  material_color_utilities:
    dependency: transitive
    description:
      name: material_color_utilities
      sha256: "0e0a020085b65b6083975e499759762399b4475f766c21668c4ecca34ea74e5a"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "0.8.0"
  meta:
    dependency: transitive
    description:
      name: meta
      sha256: d584fa6707a52763a52446f02cc621b077888fb63b93bbcb1143a7be5a0c0c04
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.11.0"
  org_flutter:
    dependency: "direct main"
    description:
      name: org_flutter
      sha256: "33cd8b357070a4bef2c29189291e88b9ddd637495954f1a069df0d0142970c4e"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "4.7.0"
  org_parser:
    dependency: transitive
    description:
      name: org_parser
      sha256: e4f6208d034ce4a14d7ead7b72e677b558addfaa6d406a8dc72d0a7d5b1d9ff7
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "5.2.0"
  path:
    dependency: transitive
    description:
      name: path
      sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.8.3"
  petit_lisp:
    dependency: transitive
    description:
      name: petit_lisp
      sha256: "10f7d5bca66ae2718d347d0e8bb8a25b385e11252873d8751e8e916db0150a1b"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "6.3.0"
  petitparser:
    dependency: transitive
    description:
      name: petitparser
      sha256: eeb2d1428ee7f4170e2bd498827296a18d4e7fc462b71727d111c0ac7707cfa6
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "6.0.1"
  plugin_platform_interface:
    dependency: transitive
    description:
      name: plugin_platform_interface
      sha256: f4f88d4a900933e7267e2b353594774fc0d07fb072b47eedcd5b54e1ea3269f8
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "2.1.7"
  sky_engine:
    dependency: transitive
    description: flutter
    source: sdk
    version: "0.0.99"
  source_span:
    dependency: transitive
    description:
      name: source_span
      sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.10.0"
  stack_trace:
    dependency: transitive
    description:
      name: stack_trace
      sha256: "73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.11.1"
  stream_channel:
    dependency: transitive
    description:
      name: stream_channel
      sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "2.1.2"
  string_scanner:
    dependency: transitive
    description:
      name: string_scanner
      sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.2.0"
  term_glyph:
    dependency: transitive
    description:
      name: term_glyph
      sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.2.1"
  test_api:
    dependency: transitive
    description:
      name: test_api
      sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "0.6.1"
  tuple:
    dependency: transitive
    description:
      name: tuple
      sha256: a97ce2013f240b2f3807bcbaf218765b6f301c3eff91092bcfa23a039e7dd151
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "2.0.2"
  typed_data:
    dependency: transitive
    description:
      name: typed_data
      sha256: facc8d6582f16042dd49f2463ff1bd6e2c9ef9f3d5da3d9b087e244a7b564b3c
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "1.3.2"
  vector_math:
    dependency: transitive
    description:
      name: vector_math
      sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803"
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "2.1.4"
  vm_service:
    dependency: transitive
    description:
      name: vm_service
      sha256: b3d56ff4341b8f182b96aceb2fa20e3dcb336b9f867bc0eafc0de10f1048e957
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "13.0.0"
  web:
    dependency: transitive
    description:
      name: web
      sha256: afe077240a270dcfd2aafe77602b4113645af95d0ad31128cc02bce5ac5d5152
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "0.3.0"
  web_socket_channel:
    dependency: transitive
    description:
      name: web_socket_channel
      sha256: d88238e5eac9a42bb43ca4e721edba3c08c6354d4a53063afaa568516217621b
      url: "https://pub.flutter-io.cn"
    source: hosted
    version: "2.4.0"
sdks:
  dart: ">=3.3.0-91.0.dev <4.0.0"
  flutter: ">=3.14.0-0"
amake commented 9 months ago

I get that on my machine too (and in CI), but it appears to be a spurious error in Flutter/Dart internals:

shelverizr commented 9 months ago

That's very strange. After I ran flutter clean and flutter pub get, I didn't have the same problem even with other projects. Maybe you should add it to the README.

amake commented 9 months ago

I figured it out. The compiler seems to not handle a typedef alias of GlobalKey that doesn't specify any type arg (despite GlobalKey having an @optionalTypeArgs annotation). I'm not sure why cleaning the project prevents the crash.

Regardless I've published a new point release that passes CI, so hopefully this won't annoy anyone else.