limelight icon indicating copy to clipboard operation
limelight copied to clipboard

Limelight segfaults every time you open a new window

Open BishBish123 opened this issue 3 years ago • 13 comments

So I have yabai set up with limelight, when I start yabai everything works smoothly. But when a new window is opened (safari, outlook etc.) limelight stops working. Running the limelight binary on its own, the output when it crashes is a segfault: limelight configuration loaded.. [1] 24635 segmentation fault /Users/<myUserName>/limelight/bin/limelight

Saving session...completed.

All I wanted was the round corners and I was fine with limelight, but I am not sure where to go from here. I have a 14" macbook pro 2021 with macos monterey

BishBish123 avatar Dec 28 '21 23:12 BishBish123

Same issue here with macos monterey.

ghost avatar Jan 08 '22 14:01 ghost

I have this issue too, Im on MacOS monterey (12.1)

andrewn6 avatar Jan 08 '22 17:01 andrewn6

I'm having the same issue, using yabai-v4.0.0 following the steps here (https://github.com/koekeishiya/yabai/issues/1054) to install yabai. I am on MacOS monterey 12.1, on M1 Silicon, boot-args -arm64e_preview_abi, and SIP disabled.

geoboom avatar Jan 15 '22 14:01 geoboom

same here

[1]    10012 segmentation fault  ~/software/limelight/bin/limelight -c
-> [139]

macOS 12.1 (21C52) i9 8950HK

eisukeesaki avatar Jan 20 '22 19:01 eisukeesaki

Limelight needs to be updated to work on Monterey. I have started doing so, but no ETA for when it is ready.

koekeishiya avatar Jan 21 '22 16:01 koekeishiya

I actually wrote a simple python script to "fix" this problem. Sort of a workaround, for now. Basically the script just loops the command to start limelight and by relying on the fact that when limelight is running the script hangs, and when limelight crashes the script becomes alive again and executes the command again to, in a way automatically restart limelight when it crashes. Here is the script:

#!/usr/bin/python3
command="/path/to/limelight"

#-------START OF SCRIPT---------
import os
i = 69
def mainModule():
        while i > 1:
                os.system(command)
mainModule()

Just copy and paste the script into a file and change the path/to/limelight to your limelight installation location, execute it with python3 and it will forever loop until you..restart your Mac. For me I run the script in screen so when I want to stop the loop I just do killall screen or pkill screen.

Wind-Explorer avatar Feb 10 '22 14:02 Wind-Explorer

Woah! Thanks for this @Wind-Explorer. Here's how I did mine:

#!/bin/bash

command="/path/to/limelight"

while true; do
	$command $@
	wait $!
done

Update: Nah, I'm not using this script anymore because this causes too much visual disruption on restarts...

chardskarth avatar Feb 10 '22 14:02 chardskarth

  1. Create com.me.limelight.plist file with following content in /Libraty/LaunchAgents directory (feel free to replace com.me.limelight with whatever you want, just something unique):
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>Label</key>
    <string>com.me.limelight</string>

    <key>KeepAlive</key>
    <true/>

    <key>RunAtLoad</key>
    <true/>

    <key>ProgramArguments</key>
    <array>
      <string>/usr/local/bin/limelight</string>
    </array>
</dict>
</plist>
  1. Replace /usr/local/bin/limelight in .plist file with your actual limelight executable location.
  2. Place your limelight config (limelightrc file) in ~/.config/limelight/ folder.
  3. chmod +x limelightrc
  4. launchd will take care of restarting limelight when it crashes.

peterdanis avatar Mar 09 '22 12:03 peterdanis

the latest version (master) of yabai (Monterey version) now comes with window borders that do not require SIP to be disabled. limelight will therefore not be updated for Monterey.

koekeishiya avatar Mar 16 '22 17:03 koekeishiya

intresting enough is that after installing the new master, im back at accessibility access window pops up all the time, and windows rearrange after changing focus

BR00l avatar Mar 16 '22 18:03 BR00l

intresting enough is that after installing the new master, im back at accessibility access window pops up all the time, and windows rearrange after changing focus

Make sure you codesign the new binary.

typkrft avatar Mar 16 '22 18:03 typkrft

intresting enough is that after installing the new master, im back at accessibility access window pops up all the time, and windows rearrange after changing focus

Make sure you codesign the new binary.

after multiple installs/uninstalls and some reboots after , everything is back to normal. smooth :)

BR00l avatar Mar 16 '22 21:03 BR00l

I just stumbled upon this yesterday and have the same issue on Monterey, is best workaround launchd?

Jbusma avatar Jul 23 '22 16:07 Jbusma