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

Intermittent VM Heap crash during hot-reload since Flutter 3.10/Dart 3.0 #126884

Closed
2 tasks done
slightfoot opened this issue May 15, 2023 · 29 comments
Closed
2 tasks done
Labels
c: crash Stack traces logged to the console c: fatal crash Crashes that terminate the process c: regression It was better in the past than it is now customer: crowd Affects or could affect many people, though not necessarily a specific customer. dependency: dart Dart team may need to help us engine flutter/engine repository. See also e: labels. found in release: 3.10 Found to occur in 3.10 needs repro info Automated crash report whose cause isn't yet known P0 Critical issues such as a build break or regression t: hot reload Reloading code during "flutter run" waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds waiting for PR to land (fixed) A fix is in flight

Comments

@slightfoot
Copy link
Member

Is there an existing issue for this?

Steps to reproduce

I am afraid I cannot reproduce with consistence, just every so often a hot-reload will crash with the reported log. Clean builds do not make a difference.

Expected results

Not to crash on hot-reload

Actual results

Crashing and application termination during hot-reload.

Code sample

No code available. This is not a framework issue. Rather a Dart/Engine issue.

Screenshots or Video

No response

Logs

Logs

Performing hot reload...
Syncing files to device Pixel C...
E/Dart    (14464): ../../third_party/dart/runtime/vm/heap/become.cc: 293: error: become: Cannot self-forward
E/DartVM  (14464): version=3.0.0 (stable) (Thu May 4 01:11:00 2023 -0700) on "android_arm64"
E/DartVM  (14464): pid=14464, thread=14533, isolate_group=main(0x794dd62800), isolate=(nil)(0x0)
E/DartVM  (14464): os=android, arch=arm64, comp=yes, sim=no
E/DartVM  (14464): isolate_instructions=794cb34720, vm_instructions=794cb34720
E/DartVM  (14464): fp=794edf3e10, sp=794edf2ce8, pc=794cc4c3b8
E/DartVM  (14464):   pc 0x000000794cc4c3b8 fp 0x000000794edf3e10 /data/app/<redacted-package-name>-irTc6R1a1fFDAlwGIgDd3w==/base.apk!/lib/arm64-v8a/libflutter.so+0x1bca3b8
E/DartVM  (14464): -- End of DumpStackTrace
F/libc    (14464): Fatal signal 6 (SIGABRT), code -6 in tid 14533 (1.ui), pid 14464 (<redacted-package-name>)
*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
Build fingerprint: 'google/ryu/dragon:8.1.0/OPM8.190605.005/5749003:user/release-keys'
Revision: '0'
ABI: 'arm64'
pid: 14464, tid: 14533, name: 1.ui  >>> <redacted-package-name> <<<
signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
Abort message: '../../third_party/dart/runtime/vm/heap/become.cc: 293: error: become: Cannot self-forward'
    x0   0000000000000000  x1   00000000000038c5  x2   0000000000000006  x3   0000000000000008
    x4   0080000000000080  x5   0080000000000080  x6   0080000000000080  x7   8000000000008000
    x8   0000000000000083  x9   0000000010000000  x10  000000794edf3df0  x11  0000000000000001
    x12  000000794edf37e8  x13  0000000000000000  x14  ffffffffffffffff  x15  0024f3b5df5e9d34
    x16  00000079f2a22fa8  x17  00000079eef314b8  x18  0000007940e04670  x19  0000000000003880
    x20  00000000000038c5  x21  0000000000000083  x22  000000780ac7aa41  x23  000000780ac7aa41
    x24  000000780ac7b1d0  x25  00000000000015fc  x26  000000794ceef910  x27  000000794d037000
    x28  0000000000000000  x29  000000794edf3e30  x30  00000079eeee66ec
    sp   000000794edf3df0  pc   00000079eeee6714  pstate 0000000060000000
backtrace:
    #00 pc 000000000001d714  /system/lib64/libc.so (abort+120)
    #01 pc 000000000048f974  /data/app/<redacted-package-name>-irTc6R1a1fFDAlwGIgDd3w==/base.apk (offset 0x2017000)

Flutter Doctor output

Doctor output
C:\>flutter doctor -v
[√] Flutter (Channel stable, 3.10.0, on Microsoft Windows [Version 10.0.19045.2965], locale en-GB)
    • Flutter version 3.10.0 on channel stable at C:\Android\flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 84a1e904f4 (6 days ago), 2023-05-09 07:41:44 -0700
    • Engine revision d44b5a94c9
    • Dart version 3.0.0
    • DevTools version 2.23.1

[√] Windows Version (Installed version of Windows is version 10 or higher)
[√] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
    • Android SDK at C:\Android\SDK
    • Platform android-33, build-tools 33.0.0
    • ANDROID_SDK_ROOT = C:\Android\SDK
    • Java binary at: C:\Program Files\Java\jdk-17\bin\java
    • Java version Java(TM) SE Runtime Environment (build 17.0.7+8-LTS-224)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe

[√] Visual Studio - develop for Windows (Visual Studio Community 2019 16.11.18)
    • Visual Studio at C:\Program Files (x86)\Microsoft Visual Studio\2019\Community
    • Visual Studio Community 2019 version 16.11.32802.440
    • Windows 10 SDK version 10.0.19041.0

[!] Android Studio (not installed)
    • Android Studio not found; download from https://developer.android.com/studio/index.html
      (or visit https://flutter.dev/docs/get-started/install/windows#android-setup for detailed instructions).

[√] IntelliJ IDEA Ultimate Edition (version 2023.1)
    • IntelliJ at C:\Users\Simon\AppData\Local\JetBrains\Toolbox\apps\IDEA-U\ch-0\231.8770.65
    • Flutter plugin version 73.1.1
    • Dart plugin version 231.9065

[√] VS Code, 64-bit edition (version 1.27.2)
    • VS Code at C:\Program Files\Microsoft VS Code
    • Flutter extension version 2.18.0

[√] Connected device (5 available)
    • Pixel C (mobile)  • 6203000067     • android-arm64  • Android 8.1.0 (API 27)
    • Pixel 4 (mobile)  • 99171FFAZ000F8 • android-arm64  • Android 13 (API 33)
    • Windows (desktop) • windows        • windows-x64    • Microsoft Windows [Version 10.0.19045.2965]
    • Chrome (web)      • chrome         • web-javascript • Google Chrome 113.0.5672.93
    • Edge (web)        • edge           • web-javascript • Microsoft Edge 112.0.1722.68

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

! Doctor found issues in 1 category.
@mkustermann
Copy link
Member

runtime/vm/heap/become.cc: 293: error: become: Cannot self-forward

/cc @rmacnak-google

I am afraid I cannot reproduce with consistence, just every so often a hot-reload will crash with the reported log. Clean builds do not make a difference.

Without reproduction this will be hard to diagnose. If you find a way to reproduce this (even if just with some probability) that would help a lot

@johannesvuorinen
Copy link

johannesvuorinen commented May 16, 2023

Happens in our app as well. In my case happened 10/10 when added (while app was running) Widget? wid; as member to StatefulWidget and then in build() returned that wid if not null - otherwise assign to that wid member the widget to be returned from that build(). When hotreloaded with those added code it crashed.

I am running M1X Mac with rosetta

../../third_party/dart/runtime/vm/heap/become.cc: 293: error: become: Cannot self-forward
version=3.0.0 (stable) (Thu May 4 01:11:00 2023 -0700) on "macos_x64"
pid=3558, thread=119835, isolate_group=main(0x7fda2f01d200), isolate=(nil)(0x0)
os=macos, arch=x64, comp=no, sim=no
isolate_instructions=131d10040, vm_instructions=131d10040
fp=318568c40, sp=318568bf0, pc=131eb82a5
  pc 0x0000000131eb82a5 fp 0x0000000318568c40 dart::Profiler::DumpStackTrace(void*)+0x85
  pc 0x0000000131d102c2 fp 0x0000000318568d20 dart::Assert::Fail(char const*, ...) const+0x92
  pc 0x0000000131f774b8 fp 0x0000000318568e00 dart::Become::Forward()+0x2d8
  pc 0x0000000131dc6c77 fp 0x0000000318569100 dart::IsolateGroupReloadContext::Reload(bool, char const*, char const*, unsigned char const*, long)+0xe07
  pc 0x0000000131dbce2c fp 0x0000000318569190 dart::IsolateGroup::ReloadSources(dart::JSONStream*, bool, char const*, char const*, bool)+0x1ac
  pc 0x0000000131f2789d fp 0x00000003185691d0 dart::ReloadSources(dart::Thread*, dart::JSONStream*)+0x16d
  pc 0x0000000131f1c6f5 fp 0x00000003185697e0 dart::Service::InvokeMethod(dart::Isolate*, dart::Array const&, bool)+0x345
  pc 0x0000000131f1ceb3 fp 0x0000000318569810 dart::Service::HandleIsolateMessage(dart::Isolate*, dart::Array const&)+0x23
  pc 0x0000000131dba59d fp 0x0000000318569db0 dart::IsolateMessageHandler::HandleMessage(std::_LIBCPP_ABI_NAMESPACE::unique_ptr<dart::Message, std::_LIBCPP_ABI_NAMESPACE::default_delete<dart::Message>>)+0x20d
  pc 0x0000000131dea130 fp 0x0000000318569e40 dart::MessageHandler::HandleMessages(dart::MonitorLocker*, bool, bool)+0x140
  pc 0x0000000131dea932 fp 0x0000000318569ea0 dart::MessageHandler::TaskCallback()+0x1f2
  pc 0x0000000131f4c4ab fp 0x0000000318569f20 dart::ThreadPool::WorkerLoop(dart::ThreadPool::Worker*)+0x15b
  pc 0x0000000131f4c9f7 fp 0x0000000318569f50 dart::ThreadPool::Worker::Main(unsigned long)+0x87
  pc 0x0000000131eb35ae fp 0x0000000318569fb0 dart::ThreadStart(void*)+0xce
  pc 0x00007ff81463f1d3 fp 0x0000000318569fd0 _pthread_start+0x7d
  pc 0x00007ff81463abd3 fp 0x0000000318569ff0 thread_start+0xf
-- End of DumpStackTrace
Lost connection to device.

@danagbemava-nc danagbemava-nc added the in triage Presently being triaged by the triage team label May 16, 2023
@danagbemava-nc
Copy link
Member

Hi @johannesvuorinen, can you provide a minimal reproducible code sample since you're also experiencing this?

@danagbemava-nc danagbemava-nc added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label May 16, 2023
@spkersten
Copy link
Contributor

Happens also in our app. Not sure how to reproduce it.

Performing hot reload...
Syncing files to device macOS...
../../third_party/dart/runtime/vm/heap/become.cc: 293: error: become: Cannot self-forward
version=3.0.0 (stable) (Thu May 4 01:11:00 2023 -0700) on "macos_arm64"
pid=37063, thread=86019, isolate_group=main(0x15613ba00), isolate=(nil)(0x0)
os=macos, arch=arm64, comp=no, sim=no
isolate_instructions=107df44a0, vm_instructions=107df44a0
fp=16fa87c00, sp=16fa87bc0, pc=107f5f464
  pc 0x0000000107f5f464 fp 0x000000016fa87c00 dart::Profiler::DumpStackTrace(void*)+0x90
  pc 0x0000000107df46fc fp 0x000000016fa87c20 dart::Assert::Fail(char const*, ...) const+0x38
  pc 0x000000010800575c fp 0x000000016fa87d00 dart::Become::Forward()+0x1d8
  pc 0x0000000107e7e8d4 fp 0x000000016fa87fd0 dart::IsolateGroupReloadContext::Reload(bool, char const*, char const*, unsigned char const*, long)+0xb8c
  pc 0x0000000107e75c04 fp 0x000000016fa88070 dart::IsolateGroup::ReloadSources(dart::JSONStream*, bool, char const*, char const*, bool)+0x1ac
  pc 0x0000000107fbab9c fp 0x000000016fa880c0 dart::ReloadSources(dart::Thread*, dart::JSONStream*)+0x1bc
  pc 0x0000000107faff18 fp 0x000000016fa886e0 dart::Service::InvokeMethod(dart::Isolate*, dart::Array const&, bool)+0x2c4
  pc 0x0000000107fb04b4 fp 0x000000016fa88710 dart::Service::HandleIsolateMessage(dart::Isolate*, dart::Array const&)+0x2c
  pc 0x0000000107e7381c fp 0x000000016fa88cc0 dart::IsolateMessageHandler::HandleMessage(std::_LIBCPP_ABI_NAMESPACE::unique_ptr<dart::Message, std::_LIBCPP_ABI_NAMESPACE::default_delete<dart::Message>>)+0x1dc
  pc 0x0000000107e9da48 fp 0x000000016fa88d50 dart::MessageHandler::HandleMessages(dart::MonitorLocker*, bool, bool)+0x148
  pc 0x0000000107e9dbcc fp 0x000000016fa88d90 dart::MessageHandler::HandleNextMessage()+0x58
  pc 0x0000000108256154 fp 0x000000016fa88e30 Dart_HandleMessage+0xf8
  pc 0x0000000107b5f1dc fp 0x000000016fa88e80 tonic::DartMessageHandler::OnHandleMessage(tonic::DartState*)+0xbc
  pc 0x0000000107b5f730 fp 0x000000016fa88eb0 std::_LIBCPP_ABI_NAMESPACE::__function::__func<tonic::DartMessageHandler::OnMessage(tonic::DartState*)::$_0, std::_LIBCPP_ABI_NAMESPACE::allocator<tonic::DartMessageHandler::OnMessage(tonic::DartState*)::$_0>, void ()>::operator()()+0x48
  pc 0x0000000107dbb1ac fp 0x000000016fa88ee0 std::_LIBCPP_ABI_NAMESPACE::__function::__func<flutter::DartIsolate::SetMessageHandlingTaskRunner(fml::RefPtr<fml::TaskRunner> const&)::$_0::operator()(std::_LIBCPP_ABI_NAMESPACE::function<void ()>) const::'lambda'(), std::_LIBCPP_ABI_NAMESPACE::allocator<flutter::DartIsolate::SetMessageHandlingTaskRunner(fml::RefPtr<fml::TaskRunner> const&)::$_0::operator()(std::_LIBCPP_ABI_NAMESPACE::function<void ()>) const::'lambda'()>, void ()>::operator()()+0x4c
  pc 0x00000001075a9694 fp 0x000000016fa88f80 fml::MessageLoopImpl::FlushTasks(fml::FlushType)+0xfc
  pc 0x00000001075b2220 fp 0x000000016fa88fb0 fml::MessageLoopDarwin::OnTimerFire(__CFRunLoopTimer*, fml::MessageLoopDarwin*)+0x34
  pc 0x00000001a9c6848c fp 0x000000016fa88fc0 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__+0x20
  pc 0x893d8001a9c68134 fp 0x000000016fa8a090 __CFRunLoopDoTimer+0x893d8000000003ac
  pc 0x68560001a9c67c8c fp 0x000000016fa8a0f0 __CFRunLoopDoTimers+0x6856000000000164
  pc 0x10708001a9c4d41c fp 0x000000016fa8ae50 __CFRunLoopRun+0x107080000000073c
  pc 0x21428001a9c4c58c fp 0x000000016fa8af00 CFRunLoopRunSpecific+0x2142800000000264
  pc 0x3e300001075b24b8 fp 0x000000016fa8af50 fml::MessageLoopDarwin::Run()+0x3e300000000000b8
  pc 0x00000001075a948c fp 0x000000016fa8af80 fml::MessageLoopImpl::DoRun()+0x3c
  pc 0x00000001075b0580 fp 0x000000016fa8afc0 void* std::_LIBCPP_ABI_NAMESPACE::__thread_proxy[abi:v15000]<std::_LIBCPP_ABI_NAMESPACE::tuple<std::_LIBCPP_ABI_NAMESPACE::unique_ptr<std::_LIBCPP_ABI_NAMESPACE::__thread_struct, std::_LIBCPP_ABI_NAMESPACE::default_delete<std::_LIBCPP_ABI_NAMESPACE::__thread_struct>>, fml::Thread::Thread(std::_LIBCPP_ABI_NAMESPACE::function<void (fml::Thread::ThreadConfig const&)> const&, fml::Thread::ThreadConfig const&)::$_0>>(void*)+0xe4
  pc 0x00000001a9b6ffa8 fp 0x000000016fa8afe0 _pthread_start+0x94
-- End of DumpStackTrace
Lost connection to device.

@luigi-rosso
Copy link

Was just coming to report this for Rive.app too and found this issue already opened. Same thing, after upgrading to Flutter 3.10 we often experience crashes when hot reloading:

../../third_party/dart/runtime/vm/heap/become.cc: 293: error: become: Cannot self-forward
version=3.0.0 (stable) (Thu May 4 01:11:00 2023 -0700) on "macos_arm64"
pid=64939, thread=33283, isolate_group=main(0x15d06e600), isolate=(nil)(0x0)
os=macos, arch=arm64, comp=no, sim=no
isolate_instructions=1076ec4a0, vm_instructions=1076ec4a0
fp=16df7fbf0, sp=16df7fbb0, pc=107857464
  pc 0x0000000107857464 fp 0x000000016df7fbf0 dart::Profiler::DumpStackTrace(void*)+0x90
  pc 0x00000001076ec6fc fp 0x000000016df7fc10 dart::Assert::Fail(char const*, ...) const+0x38
  pc 0x00000001078fd75c fp 0x000000016df7fcf0 dart::Become::Forward()+0x1d8
  pc 0x00000001077768d4 fp 0x000000016df7ffc0 dart::IsolateGroupReloadContext::Reload(bool, char const*, char const*, unsigned char const*, long)+0xb8c
  pc 0x000000010776dc04 fp 0x000000016df80060 dart::IsolateGroup::ReloadSources(dart::JSONStream*, bool, char const*, char const*, bool)+0x1ac
  pc 0x00000001078b2b9c fp 0x000000016df800b0 dart::ReloadSources(dart::Thread*, dart::JSONStream*)+0x1bc
  pc 0x00000001078a7f18 fp 0x000000016df806d0 dart::Service::InvokeMethod(dart::Isolate*, dart::Array const&, bool)+0x2c4
  pc 0x00000001078a84b4 fp 0x000000016df80700 dart::Service::HandleIsolateMessage(dart::Isolate*, dart::Array const&)+0x2c
  pc 0x000000010776b81c fp 0x000000016df80cb0 dart::IsolateMessageHandler::HandleMessage(std::_LIBCPP_ABI_NAMESPACE::unique_ptr<dart::Message, std::_LIBCPP_ABI_NAMESPACE::default_delete<dart::Message>>)+0x1dc
  pc 0x0000000107795a48 fp 0x000000016df80d40 dart::MessageHandler::HandleMessages(dart::MonitorLocker*, bool, bool)+0x148
  pc 0x0000000107795bcc fp 0x000000016df80d80 dart::MessageHandler::HandleNextMessage()+0x58
  pc 0x0000000107b4e154 fp 0x000000016df80e20 Dart_HandleMessage+0xf8
  pc 0x00000001074571dc fp 0x000000016df80e70 tonic::DartMessageHandler::OnHandleMessage(tonic::DartState*)+0xbc
  pc 0x0000000107457730 fp 0x000000016df80ea0 std::_LIBCPP_ABI_NAMESPACE::__function::__func<tonic::DartMessageHandler::OnMessage(tonic::DartState*)::$_0, std::_LIBCPP_ABI_NAMESPACE::allocator<tonic::DartMessageHandler::OnMessage(tonic::DartState*)::$_0>, void ()>::operator()()+0x48
  pc 0x00000001076b31ac fp 0x000000016df80ed0 std::_LIBCPP_ABI_NAMESPACE::__function::__func<flutter::DartIsolate::SetMessageHandlingTaskRunner(fml::RefPtr<fml::TaskRunner> const&)::$_0::operator()(std::_LIBCPP_ABI_NAMESPACE::function<void ()>) const::'lambda'(), std::_LIBCPP_ABI_NAMESPACE::allocator<flutter::DartIsolate::SetMessageHandlingTaskRunner(fml::RefPtr<fml::TaskRunner> const&)::$_0::operator()(std::_LIBCPP_ABI_NAMESPACE::function<void ()>) const::'lambda'()>, void ()>::operator()()+0x4c
  pc 0x0000000106ea1694 fp 0x000000016df80f70 fml::MessageLoopImpl::FlushTasks(fml::FlushType)+0xfc
  pc 0x0000000106eaa220 fp 0x000000016df80fa0 fml::MessageLoopDarwin::OnTimerFire(__CFRunLoopTimer*, fml::MessageLoopDarwin*)+0x34
  pc 0x00000001a794f54c fp 0x000000016df80fb0 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__+0x20
  pc 0x366c8001a794f1f4 fp 0x000000016df82080 __CFRunLoopDoTimer+0x366c8000000003ac
  pc 0x5a058001a794ed4c fp 0x000000016df820e0 __CFRunLoopDoTimers+0x5a05800000000164
  pc 0x8d418001a7934734 fp 0x000000016df82e50 __CFRunLoopRun+0x8d41800000000768
  pc 0x9e6f8001a7933878 fp 0x000000016df82f00 CFRunLoopRunSpecific+0x9e6f800000000264
  pc 0x8b4d000106eaa4b8 fp 0x000000016df82f50 fml::MessageLoopDarwin::Run()+0x8b4d0000000000b8
  pc 0x0000000106ea148c fp 0x000000016df82f80 fml::MessageLoopImpl::DoRun()+0x3c
  pc 0x0000000106ea8580 fp 0x000000016df82fc0 void* std::_LIBCPP_ABI_NAMESPACE::__thread_proxy[abi:v15000]<std::_LIBCPP_ABI_NAMESPACE::tuple<std::_LIBCPP_ABI_NAMESPACE::unique_ptr<std::_LIBCPP_ABI_NAMESPACE::__thread_struct, std::_LIBCPP_ABI_NAMESPACE::default_delete<std::_LIBCPP_ABI_NAMESPACE::__thread_struct>>, fml::Thread::Thread(std::_LIBCPP_ABI_NAMESPACE::function<void (fml::Thread::ThreadConfig const&)> const&, fml::Thread::ThreadConfig const&)::$_0>>(void*)+0xe4
  pc 0x00000001a785606c fp 0x000000016df82fe0 _pthread_start+0x94
-- End of DumpStackTrace

@danagbemava-nc danagbemava-nc added c: regression It was better in the past than it is now c: crash Stack traces logged to the console engine flutter/engine repository. See also e: labels. dependency: dart Dart team may need to help us t: hot reload Reloading code during "flutter run" c: fatal crash Crashes that terminate the process needs repro info Automated crash report whose cause isn't yet known and removed waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds in triage Presently being triaged by the triage team labels May 17, 2023
@mkustermann
Copy link
Member

Happens in our app as well. In my case happened 10/10 when added (while app was running) Widget? wid; as member to StatefulWidget and then in build() returned that wid if not null - otherwise assign to that wid member the widget to be returned from that build(). When hotreloaded with those added code it crashed.

Tried this out with a flutter create example. Adding Widget? wid to MyHomePage (StatefulWidget subclass) and then make the corresponding _MyHomePageState (State subclass) return return widget.wid ??= <...old code>. Though that doesn't reproduce it.

@johannesvuorinen If you have a 10/10 success rate reproducing it, could you try to make a minimal reproduction that can be shared?

copybara-service bot pushed a commit to dart-lang/sdk that referenced this issue May 17, 2023
Print additional information upon detecting an invalid become mapping.

TEST=ci
Bug: flutter/flutter#126884 (speculative)
Change-Id: If15713e1f25561da4a12a6f1954bd57864df18db
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/303860
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
@danagbemava-nc danagbemava-nc added customer: crowd Affects or could affect many people, though not necessarily a specific customer. found in release: 3.10 Found to occur in 3.10 labels May 19, 2023
@a-siva
Copy link
Contributor

a-siva commented May 22, 2023

@rmacnak-google has a speculative fix here https://dart-review.googlesource.com/c/sdk/+/303860, this should roll into the latest flutter builds in a day or two, @johannesvuorinen in case you are not able to produce a minimal reproduction would it be possible for you to try your current app on the latest flutter version that would have this change to see if it fixes your problem.

@johannesvuorinen
Copy link

So far seems good. I built custom engine for mac debug with the dart sdk revision containing that change.

@johannesvuorinen
Copy link

johannesvuorinen commented May 23, 2023

Multiple team members confirming that the hot reload crash is not happening anymore with the newer dart sdk revision.

@a-siva a-siva added the cp: review Cherry-picks in the review queue label May 23, 2023
@a-siva
Copy link
Contributor

a-siva commented May 23, 2023

@itsjustkevin this could be a potential candidate for cherry pick into stable, will file a cherry pick request on the Dart side

@itsjustkevin
Copy link
Contributor

itsjustkevin commented May 23, 2023

Thanks for tagging this @slightfoot and thanks for bringing it to my attention @a-siva.

I am going to remove the cp:review label as to not interfere with triage. Standing by for the cherry-pick solution.

@a-siva
Copy link
Contributor

a-siva commented May 24, 2023

@itsjustkevin here is the cherry pick request dart-lang/sdk#52508

@VirtualAstronaut
Copy link

Hello people i am facing same issue when hot reloading and or when switch index in bottom navigation( not official bottom navigation but custom made bottom navigation bar with row and container) but it started happening all of sudden. it was working just fine any temporary workaround for now? thanks! 👍

@VirtualAstronaut
Copy link

VirtualAstronaut commented May 29, 2023

@mkustermann Hello i think i have example that makes VM crash please take a look.
Thats _LeaveDataView is in column and when i don't wrap it with Expanded it crashes VM.

https://0bin.net/paste/3BUixk1g#YFT4myK99oRf-fkm+1240JSHHtfv23ML5EZE6jmrj6L

@mkustermann
Copy link
Member

@VirtualAstronaut It seems to me that the example you provided goes into an infinite loop, consuming 100% CPU and RAM consumption goes continuously up. The reason is that creating the list will make it go into an infinite loop:

          child: ListView.builder(
            shrinkWrap: true,
            itemBuilder: (context, index) {
              return _LeaveTile();
            },
          ),

=> The itemBuilder closure should return null at some point - depending on the passed index.

So this seems unrelated.

copybara-service bot pushed a commit to dart-lang/sdk that referenced this issue May 30, 2023
…Enum.values.

Print additional information upon detecting an invalid become mapping.

TEST=ci

Bug: flutter/flutter#126884
Change-Id: If15713e1f25561da4a12a6f1954bd57864df18db
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/305582
Reviewed-by: Martin Kustermann <kustermann@google.com>
Commit-Queue: Siva Annamalai <asiva@google.com>
Commit-Queue: Kevin Chisholm <kevinjchisholm@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
@qtldleon
Copy link

I am able to reproduce this issue. It happens a lot.

I have two Flutter projects, one called fishm, the other one called fishm-packages. fishm is a runnable Flutter projects, it uses some packages which are defined in fishm-packages. When I change code in fishm-packages, if I do hot reload in fishm, it crashes. This only happenes after I upgrade to Flutter 3.10.2

@mkustermann
Copy link
Member

I am able to reproduce this issue. It happens a lot. ...

Firstly, could you try with flutter master channel to confirm it still happens in newest flutter?

If so, please provide precise instructions on how to reproduce the issue - otherwise we won't be able to diagnose the root cause.

@zanderso
Copy link
Member

zanderso commented Jun 5, 2023

dart-lang/sdk@b28ac57 is now available in Flutter 3.10.3.

@a-siva
Copy link
Contributor

a-siva commented Jun 5, 2023

@qtldleon can you try your application with Flutter 3.10.3, thanks.

@Hixie
Copy link
Contributor

Hixie commented Jun 6, 2023

@slightfoot If you've been able to see this it would also be good to know if you can reproduce this with 3.10.3 (even if it's not reliably).

@Hixie Hixie added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Jun 6, 2023
@FlippedOvO
Copy link

FlippedOvO commented Jun 7, 2023

image
image
still in 3.10.3

@a-siva
Copy link
Contributor

a-siva commented Jun 7, 2023

@FlippedOvO looks like the issue you are running into is different from the one originally reported here by @slightfoot .

Can you open a new issue and provide us with some reproduction instructions so we can investigate it.

@FlippedOvO
Copy link

FlippedOvO commented Jun 8, 2023

@FlippedOvO looks like the issue you are running into is different from the one originally reported here by @slightfoot .

Can you open a new issue and provide us with some reproduction instructions so we can investigate it.

Other than the error received, everything is the same as the problem, including the operational steps.

@spkersten
Copy link
Contributor

I haven't seen any crashes on hot reload anymore after upgrading to 3.10.3

@chinmaygarde
Copy link
Member

@a-siva From Triage: Seems like we can close this as fixed in 3.10.3. Is the issue reported by @FlippedOvO tracked anywhere or are we repurposing this issue to track their observations as well? I'd prefer the former.

@a-siva
Copy link
Contributor

a-siva commented Jun 13, 2023

I have asked @FlippedOvO to open a new issue but I don't believe he has done it yet. We should not repurpose this issue to track that issue, I would prefer a new issue with a reproduction is opened.

@mjablecnik
Copy link

I had same error as @slightfoot described in main description. And after update Flutter to latest stable version 3.10.4 I don't see the error anymore.
So I think that error is solved right now :)

@qtldleon
Copy link

qtldleon commented Jun 19, 2023

@a-siva

@qtldleon can you try your application with Flutter 3.10.3, thanks.

Sorry I didn't get change to try with Flutter 3.10.3, but I tried with Flutter 3.10.5. With 3.10.5, I didn't see any same crash. Thanks for fixing this issue.

@flutter-triage-bot flutter-triage-bot bot added P0 Critical issues such as a build break or regression and removed P2 labels Jun 28, 2023
@github-actions
Copy link

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 Jul 12, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
c: crash Stack traces logged to the console c: fatal crash Crashes that terminate the process c: regression It was better in the past than it is now customer: crowd Affects or could affect many people, though not necessarily a specific customer. dependency: dart Dart team may need to help us engine flutter/engine repository. See also e: labels. found in release: 3.10 Found to occur in 3.10 needs repro info Automated crash report whose cause isn't yet known P0 Critical issues such as a build break or regression t: hot reload Reloading code during "flutter run" waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds waiting for PR to land (fixed) A fix is in flight
Projects
None yet
Development

No branches or pull requests