-
-
Notifications
You must be signed in to change notification settings - Fork 926
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
Kitty freezes after sleep/screensaver #2016
Comments
Without someway to reproduce there's not a lot I can do to help. |
I understand and don’t like sending those types of emails. I started using kitty yesterday and it has frozen multiple times on both days and only sent the message as a datapoint for you. If I can help diagnose I will send you more details. Thanks and I do appreciate the great work you are doing.
… On Oct 1, 2019, at 12:35, Kovid Goyal ***@***.***> wrote:
Without someway to reproduce there's not a lot I can do to help.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
I have noticed some freezes of kitty, too. They don't happen as frequently as @thunder-road described, more like once every two or three days, but they definitely happen. Sadly I also don't know how to reproduce yet. I am using Arch Linux, by the way, and Sway as my Wayland compositor? (So its the wayland backend for me and not the xserver one.) Do you use the |
@choreutes I don't use --single-instance. Also I've noticed a lot less of the problem I experienced earlier. In the beginning I was using the kitty as installed using |
I have been experiencing sporadic freezes as well, with no clear culprit. Almost every time while changing windows, but at least once it happened without touching the computer (but the kitty window ran a process printing data). I use |
This started happening to me after upgrading to Big Sur (running on 15in MBP 2015 with GPU). It does not always reproduce though. I took a sample of the process through Activity Monitor, don't know if this will help or not.
|
According to that its all in kernel code, mach_msgtrap and poll. Which implies events are not being delivered to kitty anymore. |
I can also attest to this. I had no problems with Kitty even on Big Sur until I updated to the latest version from Homebrew, with the same post sleep lack of responsiveness. For reference I'm launching kitty with the command |
Started to happen to me as well after the last update, not on Big Sur though, still on the latest Catalina. |
The terminal is actually working.. I can type something like "say hello" and it works.. but there's the screen shows no output. Even ctrl+d eventually closes the window, but when you add a new one is still blank. |
As a workaround, entering and exiting fullscreen may work. |
Same here, after upgrading to Big Sur kitty started randomly freezing after system wakeup. The workaround with going into fullscreen did work for me. |
i can also confirm this happening on big sur M1. i think it's not a "freeze" in the sense of not reacting, but the screen is not updated anymore. when i change terminals inside |
i have the same issue as @minusf have on a big sur verison 11.2.1 with M1 |
I'm experiencing the same issue on OSX 11.2.3 with M1. Entering and exiting fullscreen is working for me as well as a workaround. |
Been having the same issue on macOS 11.2.3 on Intel. Entering and exiting fullscreen worked for me. It happens somewhat regularly, so happy to collect whatever additional data would be helpful when it happens. |
I still cannot reproduce on Big Sur. From the various descriptions my guess would be that the monitor vsync timer (CVDisplayLink) is breaking after sleep. Run kitty with --debug-rendering and you will see messages like "No render frame received" when it happens and you generate some activity by pressing keys. |
Same here - Mojave, 2018 15" MacBook Pro. Installed from homebrew, and running current version available there. Entering full screen resolves it. Will run with --debug-rendering in /macos-launch-services-cmdline |
This is happening to me quite a bit since I upgraded to Big Sur. The full screen trick does solve it though. Is there any way for me to gather info for you @kovidgoyal to try and get to a reproduction? |
See my previous comment |
Here's the output from
|
Yeah, as I thought, its CVDisplayLink dying. Bloody Apple and their |
Somebody that can repro this needs to do some more debugging to figure out the best workaround. Apply the following patch and build kitty from source as described here: https://sw.kovidgoyal.net/kitty/build.html diff --git a/glfw/cocoa_window.m b/glfw/cocoa_window.m
index 899f6b15..4a4dc980 100644
--- a/glfw/cocoa_window.m
+++ b/glfw/cocoa_window.m
@@ -340,6 +340,8 @@ CGDirectDisplayID displayIDForWindow(_GLFWwindow *w) {
_GLFWDisplayLinkNS *dl = &_glfw.ns.displayLinks.entries[i];
if (dl->displayID == displayID) {
dl->lastRenderFrameRequestedAt = now;
+ printf("requesting render frame: original display id: %u current display id: %u display link is running: %u\n",
+ dl->displayID, CVDisplayLinkGetCurrentCGDisplay(dl->displayLink), CVDisplayLinkIsRunning(dl->displayLink));
if (!CVDisplayLinkIsRunning(dl->displayLink)) CVDisplayLinkStart(dl->displayLink);
} else if (dl->displayLink && dl->lastRenderFrameRequestedAt && now - dl->lastRenderFrameRequestedAt >= DISPLAY_LINK_SHUTDOWN_CHECK_INTERVAL) {
CVDisplayLinkStop(dl->displayLink); The repro the issue and post what gets printed |
Based on the fix in Firefox, it should be enough to detect a stuck CVDisplayLink and recreate it. I will push a fix based on that theory but I have no way to test it. |
I'm also experiencing this issue, multiple times a day on Big Sur / M1. I'm happy to test any patch/fix to see if it's still happening As with the latest brew build, it sadly still happens:
|
test the commit that closed this issue. |
Yes, the fix is not in any released version yet. |
I'll compile and give it a go. Will report back! |
So far not a single freeze! ❤️ |
Been 2 days now and sadly the freezes are back, almost guaranteed in the evening when I put the screensaver on, let the display turn off and go back to my mac the next day. Just making sure, are extra steps needed besides doing a Could someone who also had freezes give it a go and see if their experience matches? (@nerdrew?) |
Then I am out of ideas sorry. Hopefully someday apple will fix the bug with the CVDisplayLinkTimer. |
I'm experiencing this since upgrading to 0.22.1 (from 0.19.3, where I never experienced it at all) as well, but the fullscreen workaround is not working; I can only quit and restart Kitty to get it to recover. Intel Mac, Big Sur 11.5. Trying to build the latest Kitty locally (getting compile errors so far), will post back if I get any new info. Update: Just realized this is not the same bug. Kitty is sometimes hanging without me putting the machine to sleep. |
update to 0.22.2 where the fix was released |
I can now confirm that as of today Homebrew has bumped kitty's version to 0.22.2, and the 'freeze bug' (which was not present in previous versions!) has disappeared with this new release. |
On my MacBook Pro 2017 15", 10.14.5 I'm noticing that after a few hours of use it will just freeze and I have to kill it.
I've noticed this after waking the laptop from sleep and while its been locked and also while logged in and running in the background in normal use. I do not know how to reproduce this however.
The text was updated successfully, but these errors were encountered: