terminal icon indicating copy to clipboard operation
terminal copied to clipboard

WindowsTerminal.exe has stopped working

Open mailinglists35 opened this issue 3 years ago • 13 comments
trafficstars

Windows Terminal version

1.14.1451.0

Windows build number

10.0.19044.1766

Other Software

No response

Steps to reproduce

no idea. it just crashed without me doing anything this is the second time in past seven days

Expected Behavior

not crash

Actual Behavior

terminal stopped working

mailinglists35 avatar Jun 20 '22 12:06 mailinglists35

is there any way to run it with more debugging and get more diagnostic data when crashing? I don't want to enable windows os full diagnostic data, but only for the terminal

mailinglists35 avatar Jun 20 '22 12:06 mailinglists35

crashed again after I started closing tabs. after the first crash, it restored the tabs. but that is useless since the work inside them is gone and reopening 10 tabs with new shells doesn't make any sense

mailinglists35 avatar Jun 20 '22 13:06 mailinglists35

crashed a third time after ctrl-d in wsl1 shells of 7 tabs of those restored

mailinglists35 avatar Jun 20 '22 13:06 mailinglists35

crashed a fourth time after again attempting to exit those useless restored tabs

mailinglists35 avatar Jun 20 '22 13:06 mailinglists35

My only theory is that you're running into the same alt buffer / UIA crash we've been seeing in this release. What are you running in those WSL tabs? Anything like vim, emacs, tmux, anything that would use the alternate screen buffer? Also, are you running any UIA software, like Narrator, NVDA, JAWS, Magnifier/? It's a combination of those causing the crash I'm thinking of.

I honestly have no idea if this will work, but it's my usual canned response for trying to collect crash dumps:

Can you try following the steps in this post to set up automatic crash dumps? (For more info, see this link) If that works, then you should be able to automatically get a .dmp of the terminal when it crashes. Then, can you zip that dump up and send it to us, so we can investigate? Thanks!

Otherwise, the Feedback Hub is sometimes helpful, I dunno if it'll work without other diagnostics enabled in the OS: /feedback

zadjii-msft avatar Jun 20 '22 15:06 zadjii-msft

Hi there!

Can you please send us feedback with the Feedback Hub with this issue? Make sure to click the "Start recording" button, then reproduce the issue before submitting the feedback. Once it's submitted, paste the link here so we can more easily find your crash information on the back end?

Thanks!

image

image

image

ghost avatar Jun 20 '22 15:06 ghost

Hi there!Can you please send us feedback with the Feedback Hub with this issue? Make sure to click the "Start recording" button, then reproduce the issue before submitting the feedback. Once it's submitted, paste the link here so we can more easily find your crash information on the back end?Thanks!!

is it safe to leave Feedback Hub running for days after clicking Start Recording? This might take days until next crash.

mailinglists35 avatar Jun 21 '22 11:06 mailinglists35

My only theory is that you're running into the same alt buffer / UIA crash we've been seeing in this release. What are you running in those WSL tabs? Anything like vim, emacs, tmux, anything that would use the alternate screen buffer? Also, are you running any UIA software, like Narrator, NVDA, JAWS, Magnifier/? It's a combination of those causing the crash I'm thinking of.

all tabs are WSL1 with ubuntu20.04lts, inside them no alternate screen buffer apps. I only use ssh command to remote servers. One particular mention is one tab was a command prompt - I recently started to keep it open because I need to taskkill edge and explorer, because of a issue in Edge that when launches, I cannot use the start menu and taskbar at all, cannot launch new processes at all until I terminate both edge and explorer. I have reported this to edge via menu send feedback.

Can you try following the steps in this post to set up automatic crash dumps? (For more info, see this link) If that works, then you should be able to automatically get a .dmp of the terminal when it crashes. Then, can you zip that dump up and send it to us, so we can investigate? Thanks!

thank you, enabled that

mailinglists35 avatar Jun 21 '22 12:06 mailinglists35

This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment.

ghost avatar Aug 05 '22 16:08 ghost

here are some dumps. occured after windows 10 september updates reboot and windows terminal preview update. WindowsTerminal.exe.17248.zip

mailinglists35 avatar Sep 14 '22 11:09 mailinglists35

all these crashes seem to be related to opening the settings and/or closing last tab

mailinglists35 avatar Sep 14 '22 11:09 mailinglists35

I have now deleted the settings file and the number of crashed reduced to only one

crash with settings json unaltered WindowsTerminal.exe.4980.zip

mailinglists35 avatar Sep 14 '22 11:09 mailinglists35

here's one more generated when repeatedly opening and closing tabs WindowsTerminal.exe.1720.zip

mailinglists35 avatar Sep 14 '22 12:09 mailinglists35

another crash today after closed a tab WindowsTerminal.exe.18564.zip

using latest version from store image

mailinglists35 avatar Oct 06 '22 10:10 mailinglists35

image

mailinglists35 avatar Oct 06 '22 10:10 mailinglists35

one more crash after closing a tab

WindowsTerminal.exe.16812.zip

mailinglists35 avatar Oct 07 '22 12:10 mailinglists35

note that when I mean closing a tab, it is a tab that didn't exit cleanly (there is an error message in the tab, I will write it down next time). crash happens if I close this type of tab (ctrl-shift-w). if I let it open (but unusable), it doesn't crash

mailinglists35 avatar Oct 07 '22 12:10 mailinglists35

After recent Windows update (last week), I've started facing this issue while running python script. Earlier, without multi-tab terminal (this option is visible to me after recent upgrade), despite 100% CPU utilisation and heavy memory utilisation, the terminal was always accessible. But now, running the same script makes terminal 'not responding' after some time (~20-30 minutes) and it never recovers.

thdasa avatar Nov 11 '22 03:11 thdasa

Hi @mailinglists35. Sorry we haven't taken a look at this in a while. Are you still experiencing this with v1.18? If so, could you capture and share the dump file for that? Thanks!

carlos-zamora avatar May 31 '23 21:05 carlos-zamora

I haven't seen the crash since the UI changes that when I logout from WSL1 it displays the message to press enter to restart terminal tab or ctrl-d to close it

mailinglists35 avatar May 31 '23 21:05 mailinglists35

not in front of terminal right now to see what version is, but I'm on latest w10 and latest terminal update

mailinglists35 avatar May 31 '23 21:05 mailinglists35

and latest terminal update

A specific version number would be very helpful - but if you're not seeing it anymore then I bet it's one of the things that was fixed over the last few releases.

The stack is... useless:

[0x4]   ntdll!TppReportExceptionFilter+0x16   0x20cbefe3c0   0x7ffffe3e278d   
[0x5]   ntdll!TppRaiseInvalidParameter$filt$0+0xe   0x20cbefe3f0   0x7ffffe35c8c6   
[0x6]   ntdll!__C_specific_handler+0x96   0x20cbefe420   0x7ffffe36cd6e   
[0x7]   ntdll!__GSHandlerCheck_SEH+0x6a   0x20cbefe490   0x7ffffe3724df   
[0x8]   ntdll!RtlpExecuteHandlerForException+0xf   0x20cbefe4c0   0x7ffffe3214a4   
[0x9]   ntdll!RtlDispatchException+0x244   0x20cbefe4f0   0x7ffffe3211f5   
[0xa]   ntdll!RtlRaiseException+0x185   0x20cbefec00   0x7ffffe3e2764   
[0xb]   ntdll!TppRaiseInvalidParameter+0x48   0x20cbeff470   0x7ffffe2e2983   
[0xc]   ntdll!TppTimerpValidateTimer+0x6f   0x20cbeff550   0x7ffffe2e2709   
[0xd]   ntdll!TpSetTimerEx+0x39   0x20cbeff580   0x7fffcf06689b   
[0xe]   Microsoft_Terminal_Control!DllGetActivationFactory+0x24abb   0x20cbeff5e0   0x7fffcf066962   
[0xf]   Microsoft_Terminal_Control!DllGetActivationFactory+0x24b82   0x20cbeff630   0x7fffcf0736d1   
[0x10]   Microsoft_Terminal_Control!DllGetActivationFactory+0x318f1   0x20cbeff670   0x7fffcf066414   
[0x11]   Microsoft_Terminal_Control!DllGetActivationFactory+0x24634   0x20cbeff6b0   0x7fffcf13c814   
[0x12]   Microsoft_Terminal_Control!DllCanUnloadNow+0x95b54   0x20cbeff720   0x7fffcf06d4f4   
[0x13]   Microsoft_Terminal_Control!DllGetActivationFactory+0x2b714   0x20cbeff7d0   0x7fffcf06e620   
[0x14]   Microsoft_Terminal_Control!DllGetActivationFactory+0x2c840   0x20cbeff8a0   0x7fffcf06eb57   
[0x15]   Microsoft_Terminal_Control!DllGetActivationFactory+0x2cd77   0x20cbeff8d0   0x7fffcf046549   
[0x16]   Microsoft_Terminal_Control!DllGetActivationFactory+0x4769   0x20cbeff990   0x7fffcf046000   
[0x17]   Microsoft_Terminal_Control!DllGetActivationFactory+0x4220   0x20cbeff9d0   0x7fffcf046779   
[0x18]   Microsoft_Terminal_Control!DllGetActivationFactory+0x4999   0x20cbeffb30   0x7fffcf046623   
[0x19]   Microsoft_Terminal_Control!DllGetActivationFactory+0x4843   0x20cbeffbb0   0x7fffcf072ac2   
[0x1a]   Microsoft_Terminal_Control!DllGetActivationFactory+0x30ce2   0x20cbeffc00   0x7fffe8763545   
[0x1b]   TerminalConnection!winrt::Microsoft::Terminal::TerminalConnection::TerminalOutputHandler::operator()+0x15   0x20cbeffc50   0xf0bc00000001   
[0x1c]   TerminalConnection!winrt::impl::invoke<winrt::Microsoft::Terminal::TerminalConnection::TerminalOutputHandler,std::basic_string<wchar_t,std::char_traits<wchar_t>,std::allocator<wchar_t> > >+0x55   0x20cbeffc50   0xf0bc00000001   

alas

zadjii-msft avatar May 31 '23 21:05 zadjii-msft

other stack was

[0xb]   ntdll!RtlRaiseException+0x185   0x20cbefec00   0x7ffffe3e2764   
[0xc]   ntdll!TppRaiseInvalidParameter+0x48   0x20cbeff470   0x7ffffe2e2983   
[0xd]   ntdll!TppTimerpValidateTimer+0x6f   0x20cbeff550   0x7ffffe2e2709   
[0xe]   ntdll!TpSetTimerEx+0x39   0x20cbeff580   0x7fffcf06689b   
[0xf]   Microsoft_Terminal_Control!ThrottledFunc<0,winrt::Microsoft::Terminal::Control::ScrollPositionChangedArgs>::_leading_edge+0x14   0x20cbeff5e0   0x7fffcf066962   
[0x10]   Microsoft_Terminal_Control!ThrottledFunc<0,winrt::Microsoft::Terminal::Control::ScrollPositionChangedArgs>::Run<winrt::Microsoft::Terminal::Control::ScrollPositionChangedArgs &>+0xab   0x20cbeff5e0   0x7fffcf066962   
[0x11]   Microsoft_Terminal_Control!winrt::Microsoft::Terminal::Control::implementation::ControlCore::_terminalScrollPositionChanged+0x72   0x20cbeff630   0x7fffcf0736d1   
[0x12]   Microsoft_Terminal_Control!std::invoke+0x1d   0x20cbeff670   0x7fffcf066414   
[0x13]   Microsoft_Terminal_Control!std::_Invoker_ret<std::_Unforced,0>::_Call+0x1d   0x20cbeff670   0x7fffcf066414   
[0x14]   Microsoft_Terminal_Control!std::_Call_binder+0x1d   0x20cbeff670   0x7fffcf066414   
[0x15]   Microsoft_Terminal_Control!std::_Binder<std::_Unforced,void (__cdecl winrt::Microsoft::Terminal::Control::implementation::ControlCore::*)(int,int,int),winrt::Microsoft::Terminal::Control::implementation::ControlCore *,std::_Ph<1> const &,std::_Ph<2> const &,std::_Ph<3> const &>::operator()+0x1d   0x20cbeff670   0x7fffcf066414   
[0x16]   Microsoft_Terminal_Control!std::invoke+0x1d   0x20cbeff670   0x7fffcf066414   
[0x17]   Microsoft_Terminal_Control!std::_Invoker_ret<void,1>::_Call+0x1d   0x20cbeff670   0x7fffcf066414   
[0x18]   Microsoft_Terminal_Control!std::_Func_impl_no_alloc<std::_Binder<std::_Unforced,void (__cdecl winrt::Microsoft::Terminal::Control::implementation::ControlCore::*)(int,int,int),winrt::Microsoft::Terminal::Control::implementation::ControlCore *,std::_Ph<1> const &,std::_Ph<2> const &,std::_Ph<3> const &>,void,int,int,int>::_Do_call+0x21   0x20cbeff670   0x7fffcf066414   
[0x19]   Microsoft_Terminal_Control!std::_Func_class<void,int,int,int>::operator()+0x28   0x20cbeff6b0   0x7fffcf13c814   
[0x1a]   Microsoft_Terminal_Control!Microsoft::Terminal::Core::Terminal::_NotifyScrollEvent+0x84   0x20cbeff6b0   0x7fffcf13c814   
[0x1b]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::AdaptDispatch::_EraseScrollback+0x128   0x20cbeff720   0x7fffcf06d4f4   
[0x1c]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::AdaptDispatch::EraseInDisplay+0xa4   0x20cbeff7d0   0x7fffcf06e620   
[0x1d]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::VTParameters::for_each<`Microsoft::Console::VirtualTerminal::OutputStateMachineEngine::ActionCsiDispatch'::`4'::<lambda_1> >+0x30   0x20cbeff8a0   0x7fffcf06eb57   
[0x1e]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::OutputStateMachineEngine::ActionCsiDispatch+0x307   0x20cbeff8d0   0x7fffcf046549   
[0x1f]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::StateMachine::_ActionCsiDispatch::__l2::<lambda_1>::operator()+0x65   0x20cbeff990   0x7fffcf046000   
[0x20]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::StateMachine::_SafeExecute<`Microsoft::Console::VirtualTerminal::StateMachine::_ActionCsiDispatch'::`2'::<lambda_1> >+0x69   0x20cbeff990   0x7fffcf046000   
[0x21]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::StateMachine::_SafeExecuteWithLog+0xa   0x20cbeff9d0   0x7fffcf046779   
[0x22]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::StateMachine::_ActionCsiDispatch+0x1e   0x20cbeff9d0   0x7fffcf046779   
[0x23]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::StateMachine::_EventCsiParam+0x305   0x20cbeff9d0   0x7fffcf046779   
[0x24]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::StateMachine::ProcessCharacter+0x39e   0x20cbeff9d0   0x7fffcf046779   
[0x25]   Microsoft_Terminal_Control!Microsoft::Console::VirtualTerminal::StateMachine::ProcessString+0x400   0x20cbeff9d0   0x7fffcf046779   
[0x26]   Microsoft_Terminal_Control!Microsoft::Terminal::Core::Terminal::Write+0x79   0x20cbeffb30   0x7fffcf046623   
[0x27]   Microsoft_Terminal_Control!winrt::Microsoft::Terminal::Control::implementation::ControlCore::_connectionOutputHandler+0x33   0x20cbeffbb0   0x7fffcf072ac2   
[0x28]   Microsoft_Terminal_Control!winrt::Microsoft::Terminal::TerminalConnection::TerminalOutputHandler::{ctor}::__l1::<lambda_218_>::operator()+0x17   0x20cbeffc00   0x7fffe8763545   
[0x29]   Microsoft_Terminal_Control!winrt::impl::delegate<winrt::Microsoft::Terminal::TerminalConnection::TerminalOutputHandler,`winrt::Microsoft::Terminal::TerminalConnection::TerminalOutputHandler::implementation<winrt::Microsoft::Terminal::Control::implementation::ControlCore,void (__cdecl winrt::Microsoft::Terminal::Control::implementation::ControlCore::*)(winrt::hstring const &)>'::`1'::<lambda_218_> >::Invoke+0x32   0x20cbeffc00   0x7fffe8763545   
[0x2a]   TerminalConnection!winrt::Microsoft::Terminal::TerminalConnection::TerminalOutputHandler::operator()+0x15   0x20cbeffc50   0x7fffe876319f   
[0x2b]   TerminalConnection!winrt::impl::invoke<winrt::Microsoft::Terminal::TerminalConnection::TerminalOutputHandler,std::basic_string<wchar_t,std::char_traits<wchar_t>,std::allocator<wchar_t> > >+0x55   0x20cbeffc50   0x7fffe876319f   
[0x2c]   TerminalConnection!winrt::event<winrt::Microsoft::Terminal::TerminalConnection::TerminalOutputHandler>::operator()+0x56   0x20cbeffcb0   0x7fffe876bf3e   
[0x2d]   TerminalConnection!winrt::Microsoft::Terminal::TerminalConnection::implementation::ConptyConnection::_OutputThread+0x1ff   0x20cbeffcb0   0x7fffe876bf3e   
[0x2e]   TerminalConnection!winrt::Microsoft::Terminal::TerminalConnection::implementation::ConptyConnection::Start::__l3::<lambda_1>::operator()+0xa   0x20cbeffd80   0x7ffffd6e7034   
[0x2f]   TerminalConnection!_Closure_wrapper_30d40180_14::<lambda_invoker_cdecl>+0xe   0x20cbeffd80   0x7ffffd6e7034   


I'm pretty confident there's a dupe for that.

zadjii-msft avatar May 31 '23 22:05 zadjii-msft

This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment.

This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment.

@zadjii-msft That second stack trace looks similar to #13880, which was fixed in PR #13882, so it's possible at least some of the crashes reported in this issue are now fixed.

j4james avatar Jun 08 '23 01:06 j4james

Thanks for doing the diligence! That looks like the right one, just didn't have time to find it before going on leave ☺️

zadjii-msft avatar Jun 08 '23 11:06 zadjii-msft