Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash when compiling after "Flutter build ios" on macOS #76011

Closed
PiechKevin opened this issue Feb 14, 2021 · 1 comment
Closed

Crash when compiling after "Flutter build ios" on macOS #76011

PiechKevin opened this issue Feb 14, 2021 · 1 comment

Comments

@PiechKevin
Copy link

PiechKevin commented Feb 14, 2021

Hello, in a new Flutter project created by Andoid Studio on macOS, i can't launch the app an ios 14 device (or emulator).

When i try to use the commande "flutter build ios" i have this log:

 ../../Desktop/flutter/packages/flutter/lib/src/widgets/widget_inspector.dart:741:63: Error: Method not found: 'Map.identity'.
      final Map<Object, String> _objectToId = Map<Object, String>.identity();
                                                                  ^^^^^^^^
    Unhandled exception:
    Crash when compiling file:///Users/kevinpiech/Desktop/flutter/packages/flutter/lib/src/widgets/widget_inspector.dart,
    at character offset 26588:
    Bad state: No element
    #0      List.single (dart:core-patch/growable_array.dart:260:22)
    #1      ClassBuilderImpl.buildTypesWithBuiltArguments (package:front_end/src/fasta/builder/class_builder.dart:568:43)
    #2      ClassBuilderImpl.buildType (package:front_end/src/fasta/builder/class_builder.dart:623:12)
    #3      NamedTypeBuilder.build (package:front_end/src/fasta/builder/named_type_builder.dart:275:24)
    #4      FunctionTypeBuilder.build (package:front_end/src/fasta/builder/function_type_builder.dart:81:21)
    #5      BodyBuilder.buildDartType (package:front_end/src/fasta/kernel/body_builder.dart:6285:11)
    #6      BodyBuilder.endFormalParameter (package:front_end/src/fasta/kernel/body_builder.dart:3480:7)
    #7      Parser.parseFormalParameter (package:_fe_analyzer_shared/src/parser/parser_impl.dart:1632:14)
    #8      Parser.parseOptionalNamedParameters (package:_fe_analyzer_shared/src/parser/parser_impl.dart:1704:11)
    #9      Parser.parseFormalParametersRest (package:_fe_analyzer_shared/src/parser/parser_impl.dart:1342:17)
    #10     Parser.parseFormalParameters (package:_fe_analyzer_shared/src/parser/parser_impl.dart:1316:12)
    #11     Parser.parseFormalParametersOpt (package:_fe_analyzer_shared/src/parser/parser_impl.dart:1276:15)
    #12     DietListener.buildFunctionBody (package:front_end/src/fasta/source/diet_listener.dart:976:22)
    #13     DietListener._endClassMethod (package:front_end/src/fasta/source/diet_listener.dart:714:5)
    #14     DietListener.endMixinMethod (package:front_end/src/fasta/source/diet_listener.dart:679:5)
    #15     Parser.parseMethod (package:_fe_analyzer_shared/src/parser/parser_impl.dart:3809:20)
    #16     Parser.parseClassOrMixinOrExtensionMemberImpl (package:_fe_analyzer_shared/src/parser/parser_impl.dart:3546:15)
    #17     Parser.parseClassOrMixinOrExtensionBody (package:_fe_analyzer_shared/src/parser/parser_impl.dart:3220:15)
    #18     Parser.parseMixin (package:_fe_analyzer_shared/src/parser/parser_impl.dart:2100:13)
    #19     Parser.parseTopLevelKeywordDeclaration (package:_fe_analyzer_shared/src/parser/parser_impl.dart:619:18)
    #20     Parser.parseTopLevelDeclarationImpl (package:_fe_analyzer_shared/src/parser/parser_impl.dart:476:14)
    #21     Parser.parseUnit (package:_fe_analyzer_shared/src/parser/parser_impl.dart:356:15)
    #22     SourceLoader.buildBody (package:front_end/src/fasta/source/source_loader.dart:427:14)
    <asynchronous suspension>
    #23     Loader.buildBodies (package:front_end/src/fasta/loader.dart:242:15)
    <asynchronous suspension>
    #24     KernelTarget.buildComponent.<anonymous closure> (package:front_end/src/fasta/kernel/kernel_target.dart:382:20)
    #25     withCrashReporting (package:front_end/src/fasta/crash.dart:122:24)
    #26     KernelTarget.buildComponent (package:front_end/src/fasta/kernel/kernel_target.dart:380:12)
    #27     generateKernelInternal.<anonymous closure> (package:front_end/src/kernel_generator_impl.dart:177:38)
    <asynchronous suspension>
    #28     generateKernelInternal.<anonymous closure> (package:front_end/src/kernel_generator_impl.dart)
    #29     withCrashReporting (package:front_end/src/fasta/crash.dart:122:24)
    #30     generateKernelInternal (package:front_end/src/kernel_generator_impl.dart:73:10)
    #31     kernelForProgramInternal.<anonymous closure> (package:front_end/src/api_prototype/kernel_generator.dart:61:35)
    #32     CompilerContext.runWithOptions.<anonymous closure> (package:front_end/src/fasta/compiler_context.dart:135:20)
    <asynchronous suspension>
    #33     CompilerContext.runWithOptions.<anonymous closure> (package:front_end/src/fasta/compiler_context.dart)
    #34     CompilerContext.runInContext.<anonymous closure>.<anonymous closure> (package:front_end/src/fasta/compiler_context.dart:123:46)
    #35     new Future.sync (dart:async/future.dart:223:31)
    #36     CompilerContext.runInContext.<anonymous closure> (package:front_end/src/fasta/compiler_context.dart:123:19)
    #37     _rootRun (dart:async/zone.dart:1190:13)
    #38     _CustomZone.run (dart:async/zone.dart:1093:19)
    #39     _runZoned (dart:async/zone.dart:1630:10)
    #40     runZoned (dart:async/zone.dart:1550:10)
    #41     CompilerContext.runInContext (package:front_end/src/fasta/compiler_context.dart:122:12)
    #42     CompilerContext.runWithOptions (package:front_end/src/fasta/compiler_context.dart:133:10)
    #43     kernelForProgramInternal (package:front_end/src/api_prototype/kernel_generator.dart:60:32)
    #44     kernelForProgram (package:front_end/src/api_prototype/kernel_generator.dart:52:17)
    #45     compileToKernel (package:vm/kernel_front_end.dart:381:28)
    #46     FrontendCompiler.compile.<anonymous closure> (package:frontend_server/frontend_server.dart:542:54)
    #47     new Future.<anonymous closure> (dart:async/future.dart:175:37)
    #48     _rootRun (dart:async/zone.dart:1182:47)
    #49     _CustomZone.run (dart:async/zone.dart:1093:19)
    #50     _CustomZone.runGuarded (dart:async/zone.dart:997:7)
    #51     _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:1037:23)
    #52     _rootRun (dart:async/zone.dart:1190:13)
    #53     _CustomZone.run (dart:async/zone.dart:1093:19)
    #54     _CustomZone.bindCallback.<anonymous closure> (dart:async/zone.dart:1021:23)
    #55     Timer._createTimer.<anonymous closure> (dart:async-patch/timer_patch.dart:18:15)
    #56     _Timer._runTimers (dart:isolate-patch/timer_impl.dart:397:19)
    #57     _Timer._handleMessage (dart:isolate-patch/timer_impl.dart:428:5)
    #58     _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:168:12)


    #0      DietListener.buildFunctionBody (package:front_end/src/fasta/source/diet_listener.dart:998:7)
    #1      DietListener._endClassMethod (package:front_end/src/fasta/source/diet_listener.dart:714:5)
    #2      DietListener.endMixinMethod (package:front_end/src/fasta/source/diet_listener.dart:679:5)
    #3      Parser.parseMethod (package:_fe_analyzer_shared/src/parser/parser_impl.dart:3809:20)
    #4      Parser.parseClassOrMixinOrExtensionMemberImpl (package:_fe_analyzer_shared/src/parser/parser_impl.dart:3546:15)
    #5      Parser.parseClassOrMixinOrExtensionBody (package:_fe_analyzer_shared/src/parser/parser_impl.dart:3220:15)
    #6      Parser.parseMixin (package:_fe_analyzer_shared/src/parser/parser_impl.dart:2100:13)
    #7      Parser.parseTopLevelKeywordDeclaration (package:_fe_analyzer_shared/src/parser/parser_impl.dart:619:18)
    #8      Parser.parseTopLevelDeclarationImpl (package:_fe_analyzer_shared/src/parser/parser_impl.dart:476:14)
    #9      Parser.parseUnit (package:_fe_analyzer_shared/src/parser/parser_impl.dart:356:15)
    #10     SourceLoader.buildBody (package:front_end/src/fasta/source/source_loader.dart:427:14)
    <asynchronous suspension>
    #11     Loader.buildBodies (package:front_end/src/fasta/loader.dart:242:15)
    <asynchronous suspension>
    #12     KernelTarget.buildComponent.<anonymous closure> (package:front_end/src/fasta/kernel/kernel_target.dart:382:20)
    #13     withCrashReporting (package:front_end/src/fasta/crash.dart:122:24)
    #14     KernelTarget.buildComponent (package:front_end/src/fasta/kernel/kernel_target.dart:380:12)
    #15     generateKernelInternal.<anonymous closure> (package:front_end/src/kernel_generator_impl.dart:177:38)
    <asynchronous suspension>
    #16     generateKernelInternal.<anonymous closure> (package:front_end/src/kernel_generator_impl.dart)
    #17     withCrashReporting (package:front_end/src/fasta/crash.dart:122:24)
    #18     generateKernelInternal (package:front_end/src/kernel_generator_impl.dart:73:10)
    #19     kernelForProgramInternal.<anonymous closure> (package:front_end/src/api_prototype/kernel_generator.dart:61:35)
    #20     CompilerContext.runWithOptions.<anonymous closure> (package:front_end/src/fasta/compiler_context.dart:135:20)
    <asynchronous suspension>
    #21     CompilerContext.runWithOptions.<anonymous closure> (package:front_end/src/fasta/compiler_context.dart)
    #22     CompilerContext.runInContext.<anonymous closure>.<anonymous closure> (package:front_end/src/fasta/compiler_context.dart:123:46)
    #23     new Future.sync (dart:async/future.dart:223:31)
    #24     CompilerContext.runInContext.<anonymous closure> (package:front_end/src/fasta/compiler_context.dart:123:19)
    #25     _rootRun (dart:async/zone.dart:1190:13)
    #26     _CustomZone.run (dart:async/zone.dart:1093:19)
    #27     _runZoned (dart:async/zone.dart:1630:10)
    #28     runZoned (dart:async/zone.dart:1550:10)
    #29     CompilerContext.runInContext (package:front_end/src/fasta/compiler_context.dart:122:12)
    #30     CompilerContext.runWithOptions (package:front_end/src/fasta/compiler_context.dart:133:10)
    #31     kernelForProgramInternal (package:front_end/src/api_prototype/kernel_generator.dart:60:32)
    #32     kernelForProgram (package:front_end/src/api_prototype/kernel_generator.dart:52:17)
    #33     compileToKernel (package:vm/kernel_front_end.dart:381:28)
    #34     FrontendCompiler.compile.<anonymous closure> (package:frontend_server/frontend_server.dart:542:54)
    #35     new Future.<anonymous closure> (dart:async/future.dart:175:37)
    #36     _rootRun (dart:async/zone.dart:1182:47)
    #37     _CustomZone.run (dart:async/zone.dart:1093:19)
    #38     _CustomZone.runGuarded (dart:async/zone.dart:997:7)
    #39     _CustomZone.bindCallbackGuarded.<anonymous closure> (dart:async/zone.dart:1037:23)
    #40     _rootRun (dart:async/zone.dart:1190:13)
    #41     _CustomZone.run (dart:async/zone.dart:1093:19)
    #42     _CustomZone.bindCallback.<anonymous closure> (dart:async/zone.dart:1021:23)
    #43     Timer._createTimer.<anonymous closure> (dart:async-patch/timer_patch.dart:18:15)
    #44     _Timer._runTimers (dart:isolate-patch/timer_impl.dart:397:19)
    #45     _Timer._handleMessage (dart:isolate-patch/timer_impl.dart:428:5)
    #46     _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:168:12)


    note: Using new build system
    note: Building targets in parallel
    note: Planning build
    note: Constructing build description

Encountered error while building for device.

I seach a solution but i don't understant the problem :/

@github-actions
Copy link

github-actions bot commented Aug 5, 2021

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 5, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant