Look upon my OBS hell and despair

So, you just wanna stream 24/7, and occasionally switch input on a timer? How hard could that be?

For your amusement, read the comments in the ~2000 line sh script that keeps DNA Lounge running.

Here be monsters.

When I say that almost all of my coding stems from either self defense or spite, this is what I mean.


Previously, previously, previously, previously.

Tags: , , , ,

20 Responses:

  1. mdhughes says:

    I was gonna say, Audio Hijack Pro absolutely does have AppleScript, I used to use that all the time… But it looks like they took it out when they dropped the Pro & made the new "Audio Hijack". I dunno what's going on there, but that's madness. There's no scripting in it at all?

  2. Ben says:

    Sometimes macOS gets into a state where no AVPlayer or QuickTime-based
    # app can play video at all: the videos play in super-fast-forward until
    # they reach the end and stop

    I had this happen to me frequently on a previous MBP. In my case I narrowed it down to something to do with manipulating the system audio output. The laptop's left speaker blew out and made using the built-in audio impossible so I had installed eqMac to force pan everything to the right speaker. Every so often video would do the same thing as you describe. Eventually always using speakers / headphones and never launching eqMac kept that weird video speedup from happening. Maybe you could route the audio output to another physical device to do the icecast streaming instead of audio hijack? Just one bullet point on your long list of OBS shortcomings, though.

    • jwz says:

      I'm using Audio Hijack and Loopback to route audio in several different ways, and that's not optional for my setup. It is not clear what triggers the coreaudiod bug, but none of the audio stuff I'm doing can just be omitted.

  3. Pavel says:

    I've mostly given up on being able to reliably do things in cron on OS X; instead, my cron jobs end up sending commands to an always-running tmux server, and running them in a new pane.

    Apparently, you're just not supposed to do things with crons anymore - launchtl is the hip new way of doing things that also didn't fucking work for me, hence my horrendous tmux concoction.

    • jwz says:

      You can make cron work, you just have to dick around endlessly in System Preferences first, marking everything including the kitchen sink an "assistive access" or "full disk" program. And then you still probably have to click on a dialog box the first time something does a thing.

      "Anything done for the first time unleashes a demon."

  4. jwz says:

    Adding AppleScript bindings to all of your GUI elements is actually surprisingly easy to do, so it's borderline malpractice that neither OBS nor Audio Hijack could be bothered to do this.

    Rogue Amoeba's response to my Audio Hijack bug report saying "Y U NO AUTOMATE" was, 'Yeah, people ask for that all the time." That was over a year ago.

    Many of my problems with Audio Hijack would be fixed by a checkbox in preferences that just says, "Auto-play at startup". Not even full automation support, merely "launch in a functional state without requiring me to wait several seconds and then interactively click the mouse."

  5. prefetch says:

    Your Roland VC-1DL is totes vulnerable:

    telnet to the RPC-3 Telnet daemon on the standard telnet port, and when prompted for the username hit the escape key, and then enter. The attacker will then be logged into the Telnet Daemon.

    This attack was tested on RPC-3 Telnet Host version 3.05.

  6. Nibby says:

    I love shell scripts that hard power cycle stuff. Your syslogs must be great comedy. I'm sure it'll be "fun" when they get rid of applescript. I wish my shell could help you, but it's just all things have to be wacked. But this looks solid compared to much worse such scripts I've seen that the world runs on.

  7. Jim says:

    If I'm viewing your streams in an ordinary browser, Jamie, how many clicks does it take to donate to you, and do you give your donors immediate recognition on e.g. the bus sign?

  8. Placid says:

    I guess you’re not using Big Sur. Otherwise your list of randomly popping problems would have included:
    - suddenly, in the middle of your active work an unkillable screensaver pops up and does not go away no matter what. Reboot helps.

    There are long salt threads beginning in November. Check “M1 screensaver bug”. Marked “fixed”. Still happening to me on a squeaky new M1 Mini with a squeaky new 11.3. Some reported happening on Intel too.
    ——
    Also: people have designed and are selling for $10 on Amazon a small _hardware_ thingy that can be inserted in a headless Mac and which pretends to be a display of a very high resolution. This allows you to set VNC session to something better than 1920x1280. (Name: fit-headless).

    Think of it: custom-designed hardware to circumvent lack of configuration in software...

    • jwz says:

      Those are called "EDID Ghosts" and they are super handy. I've used them for years in various applications. They are little pass-through HDMI dongles that intercept the resolution-negotiation portion of the HDMI setup and hardcode it to (say) 1080p60. That means that when you unplug a monitor, the host computer doesn't know that it has gone away and just keeps transmitting. It prevents the screen from going black for 10 seconds if you sneeze on the cable, and helps stability on long runs.

      • Placid says:

        Thought you will be more interested in screensaver stuff :)

        Cause I really don’t understand how it is even _possible_ to design a screensaver behavior this way. No, I understand how it can be launched at a wrong time, like: easily. But why the behavior differs - between a properly launched ss and an improperly launched one?

        Looks like the keypress processor does not know that there is a screensaver launched if the ss was not launched properly - such “launched, but unregistered” thing should never happen with an experienced designer, but anyway should have been fixed easily: make the app itself register or whatever is needed for others to terminate it. But - 5 months? 3 major software releases?

        The old Mac Pro I was hoping to replace reboots once per day due to hardware issues, this new shiny thing needs reboot after 20 mins sometimes, lol.

      • Doctor Memory says:

        Holy crap, I had no idea that such things existed, and learning about them is absolutely the best thing that's happened to me this month so far. An entire class of problems I can make go away...

  9. eta says:

    This reminds me of marcan's multiple hour long work stream trying to fix OBS audio hangs. I get the impression this codebase isn't as reliable as people seem to make it seem...

    • jwz says:

      Who has described it as reliable? Ubiquitous, sure. Without plausible alternatives, also sure.

      It's basically Photoshop: universally used, widely despised, probably won't crash and screw up days of work most of the time. Most of the time.

  • Previously