-
Notifications
You must be signed in to change notification settings - Fork 450
Description
Hey
I've run into a consistent issue with the Kitty terminal integration on desktop. The problem looks to be a race condition on the launch.
XPipe launches kitty --detach
but attempts to use the communication socket with socat almost immediately.
Leaving not enough time for the socket to be created and causing socat to write a regular file instead, which breaks the connection.
This broken file then causes all subsequent launches (for simple shells or Zellij to fail with an Invalid listen_on
Errors parsing configuration
In final effective configuration:
Invalid listen_on=unix:/tmp/xpipe/fredzer/xpipe_kitty, ignoring
Press Enter or Esc to exit
$ ls -ld /tmp/xpipe/fredzer/xpipe_kitty
Socket file
Invalid State -
-rw-r--r-- 1 /tmp/xpipe/fredzer/xpipe_kitty
Good State -
srwxr-xr-x 1 /tmp/xpipe/fredzer/xpipe_kitty
Environment:
- XPipe Version: 18.7/2025-09-17-05-52
- Operating System: EndeavourOS (Arch Linux)
- Hardware: Intel i9-10900K, NVMe Storage
Logs:
The logs show socat
is called less than 200ms after kitty
is launched, which triggers the race condition.
From the log + debug output steps- I've ran the commands manually (human speed) and kitty socket is created > open new kitty connection and connect just fine, so it does the job but its then tripping its self up.
Source Code:
This seems to be caused by the timing heuristic in KittyTerminalType.java
var elapsed = System.currentTimeMillis() - time;
// Good heuristic on how long to wait
ThreadHelper.sleep(5 * elapsed);
I've patched with timer wrappers for a while but wanted to raise it here as I haven't seen any similar issues logged.