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 opening a new tab or window, or any non-default profile #15446

Closed
sboukortt opened this issue May 25, 2023 · 20 comments
Closed

Crash when opening a new tab or window, or any non-default profile #15446

sboukortt opened this issue May 25, 2023 · 20 comments
Labels
Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Attention The core contributors need to come back around and look at this ASAP. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting

Comments

@sboukortt
Copy link

Windows Terminal version

1.18.1421.0

Windows build number

10.0.19045.0

Other Software

No response

Steps to reproduce

Open two tabs or two windows.

Expected Behavior

Two tabs are opened and can be used.

Actual Behavior

Opening the second tab or window triggers a crash of the entire application, taking both tabs/windows with it.

Windows Terminal 1.16.10261.0 with the same configuration works as expected.

@sboukortt sboukortt added Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting labels May 25, 2023
@sboukortt
Copy link
Author

I saw an open issue that I thought might be related but the discussion suggests that that other issue is specific to when focusFollowMouse is enabled, and I have it disabled.

@lhecker
Copy link
Member

lhecker commented May 26, 2023

Yesterday, when running a debug build off of main, I also had it crashing, and it was due to GetRootPane() returning nullptr right here:

terminalTab->GetRootPane()->WalkTree([&](auto&& pane) {
if (auto control = pane->GetTerminalControl())
{
control.WindowVisibilityChanged(showOrHide);
}
});

Curiously this issue has never occurred before on my PC.

@sboukortt
Copy link
Author

Oh, interesting, thanks. Is it something that would be reasonably easy to bisect?

@lhecker
Copy link
Member

lhecker commented May 26, 2023

It's not really something that needs to be bisected, because as far as I can tell, the exact same code ran perfectly fine for the last year on my PC. Rather, I suspect that some unrelated change has changed the order of initialization slightly to allow for visibility change messages to arrive sooner. This could've for instance happened, because I made the startup of Windows Terminal vastly (>2x) faster.
Although we'll only know if you're victim of the same issue if you either debug Windows Terminal yourself (for instance via WinDbg; you can find it in the App Store) or capture a crash dump for us (see here). Otherwise, we'll automatically receive minidumps of this crash within a week or so, if you have telemetry enabled.

@zadjii-msft
Copy link
Member

Yea, we'll need a stack or something to investigate here.

If you file /feedback with the Feedback Hub, we might be able to reverse engineer that in the backend and find crashes that have already happened. Unlikely, but worth a shot.

If it repros consistently though, then just trying to repro it with the feedback hub's "Recreate my problem" recorder should grab the dump.
image

@microsoft-github-policy-service
Copy link
Contributor

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

@microsoft-github-policy-service microsoft-github-policy-service bot added the Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something label May 26, 2023
@dziban303
Copy link

Same thing is happening for me. Normally it's intermittent—usually, I can open a new tab without issue. I'd say that the issue manifests maybe 20% of the time. Luckily, it happened every single time when recording it with Feedback Hub, a Vorführeffekt in my favor for a change 😂

@zadjii-msft
Copy link
Member

@dziban303 can you share the Feedback Hub link here?

@dziban303
Copy link

Hey @zadjii-msft sorry. Here's the link https://aka.ms/AAkzyij

@zadjii-msft
Copy link
Member

I won't be able to take a look till tomorrow at the earliest, but as a sanity check, does https://github.com/microsoft/terminal/releases/tag/v1.18.1462.0 work? That has some hotfixes for... kinda a lot of bugs...

@dziban303
Copy link

Thanks, it was literally installing via the Store when you sent that. I'll give it a whirl later tonight. Cheers

@sboukortt
Copy link
Author

Sadly, it still reproduces for me. It also seems not to always respect the window transparency I have set, and it crashes when going to “Settings” -> (“Profiles” ->) “Defaults” -> “Appearance” where one would set it. Could that be related?

I tried to file feedback with the Feedback Hub but couldn’t quite figure out whether it would record crash data for Terminal Preview if I select “Terminal” as the app (Terminal Preview isn’t offered as a choice). Does it?

@microsoft-github-policy-service microsoft-github-policy-service bot added Needs-Attention The core contributors need to come back around and look at this ASAP. and removed Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something labels May 29, 2023
@zadjii-msft
Copy link
Member

Okay so ai was able to find a dump from @dziban303's machine (even if Feedback Hub wasn't the most cooperative). It looks like you're hitting the "focusFollowMouse": true crash. That was tracked in #15412, and should be fixed in https://github.com/microsoft/terminal/releases/tag/v1.18.1462.0.

@sboukortt - you've got that setting disabled, so presumably you're seeing something new. Can you file the same Feedback Hub steps above/? That should help us find the dump on the backend.

@microsoft-github-policy-service microsoft-github-policy-service bot added Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something and removed Needs-Attention The core contributors need to come back around and look at this ASAP. labels May 30, 2023
@sboukortt
Copy link
Author

I am not sure what changed but it doesn’t seem to be happening anymore? That’s still with v1.18.1462.0.

The main change I can think of that could possibly have to do with this is that I upgraded my graphics driver (NVIDIA) to 535.98, from the previous “studio” driver (I don’t remember which version that was).

@microsoft-github-policy-service microsoft-github-policy-service bot added Needs-Attention The core contributors need to come back around and look at this ASAP. and removed Needs-Author-Feedback The original author of the issue/PR needs to come back and respond to something labels May 31, 2023
@DHowett
Copy link
Member

DHowett commented Jun 1, 2023

Wow, okay, that's weird. Since we lost our repro, I'm gonna close this one out. Please don't hesitate to yell at us if it comes back!

@DHowett DHowett closed this as completed Jun 1, 2023
@sboukortt
Copy link
Author

sboukortt commented Jun 22, 2023

For some reason, it seems to be happening again since my last reboot. (I usually use hybrid shutdown / “fast startup” rather than a full reboot.) The version of Terminal Preview is still v1.18.1462.0.

I am getting the impression that there is something that causes it to either happen reliably or not at all after every reboot, which is rather mysterious. Thankfully, if that is the case, it means I have until my next full reboot to figure out how to get a proper stacktrace.

@sboukortt
Copy link
Author

sboukortt commented Jul 25, 2023

I still haven’t gotten around to doing that, but for what it’s worth, the other day, I updated my GPU driver and it seems to have crashed Terminal Preview but not Terminal.

@zhangjy859
Copy link

Hi @sboukortt

I also have the same issue after a system reboot, Could you please give me some suggestions? I have feedback with feedback hub

@zadjii-msft
Copy link
Member

@zhangjy859 Do you have MacType installed by any chance? If so, go update it. Older versions of that will crash the Terminal.

If not, could you share the link to your feedback in Feedback Hub here in this thread? Thanks!

@zhangjy859
Copy link

zhangjy859 commented May 13, 2024

@zhangjy859 Do you have MacType installed by any chance? If so, go update it. Older versions of that will crash the Terminal.

If not, could you share the link to your feedback in Feedback Hub here in this thread? Thanks!

Yeah, I have MacType, I have tried update it and uninstall it, but not work, however, as @sboukortt's comment, I updated my GPU graphic driver, Its ok.

Interestingly, this is my workstation and for a considerable amount of time, it had a fixed version of Windows Terminal, MacType, and graphics drivers, and they worked without any issues. I'm not sure why there was a change after a restart. In any case, updating the graphics drivers could be helpful.

Thank you for your prompt reply and assistance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Bug It either shouldn't be doing this or needs an investigation. Needs-Attention The core contributors need to come back around and look at this ASAP. Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting
Projects
None yet
Development

No branches or pull requests

6 participants