MIDI drops with Ardour 9.7 on Ubuntu 26

Hi -

I’ve recently upgraded my rig to Ubuntu 26, and am experiencing a problem with Ardour 9.7 that I didn’t see on Ubuntu 24. It’s Pipewire-related, so the interaction is probably with Pipewire 1.6.x; Ubuntu 24 used Pipewire 1.0.5. I’m running on ARM (Raspberry Pi 5); not sure if that’s relevant or not.

The problem appears (for me) because I have a MIDI input bus that I connect my physical (and virtual) MIDI controllers to and then connect the output of that bus to five or six other tracks. The symptom is that MIDI messages get dropped before they get to the other tracks. The problem is related to the fan-out. If I connect the input controller directly to one of those other five tracks, it works fine.

And it’s intermittent - sometimes I see 100% drops, sometimes roughly half of the messages get through.

I’m investigating it, and will report when I know more. In the meantime, I just wanted to open a thread here in case others are running on Ubuntu 26 and see something similar.

1 Like

Same issue, I moved to classic jack to solve that problem. I wanted to move back to pipewire now, but I guess better not…

Arch linux in my case, with an earlier Ardour version. Same setup, single buss to hardware, from there to multiple instrument tracks in ardour. Same issue, hardware to buss worked, but nothing got to the instruments…

Claude is pretty sure it’s a race condition in pipewire-jack, and I tend to concur. The AI has written a 189-line C program that triggers the bug without needing Ardour and we’ve opened an issue on Pipewire’s development site:

I don’t think this is limited to Ardour 9.7 or Ubuntu 26; this has been there a while. For some reason, my rig just didn’t trigger it on Ubuntu 24.

2 Likes

This has now been fixed in Pipewire (see the issue linked above), and I can confirm that Pipewire 1.6.6, plus Wim Taymans’ patch, resolves the issue on my rig.

Obviously, we’ll have to wait a while before this makes it into distributed versions of Pipewire.

2 Likes

Wow this has been bugging me for a while

midi controller → track → multiple buses was doing my head in the events just wouldn’t propagate from the track to the bus.

Thankyou for tracking it down
(debian sid)

@nevyn You’re welcome! Thank you for posting; it’s nice to know that my efforts help someone else.

I didn’t see any problem on Ubuntu 24. For some reason, when I switched to Ubuntu 26, suddenly it manifested. Often the biggest problem in software debugging is getting a problem to reproduce reliably.

It was immediately apparent that I could resolve the problem by switching the MIDI input to feed the tracks directly, so obviously it was a problem with the fan-out bus. I just fed that information into the AI and turned it loose. It’s “agentic”, meaning tool using, and in this case the tools were bash (and everything you can do from the command line, include using the gdb debugger and recompiling software with extra instrumentation) and VNC (so it could operate the GUI). I’ve kept all of the logs.

First it updated to the latest Pipewire, then it thought the problem was that audio-typed buses couldn’t carry MIDI, then it thought it had fixed it by setting PIPEWIRE_MIDI_BROKEN, but three days later I was still having the same problem. Then it came up with a workaround that did fix the problem, and a few days after that I pushed it to really identify the problem and come up with a short program that could reproduce it. It also came up with a theory about what the bug actually was, so I had it post all of that to the Pipewire website. Within 24 hours, Wim Taymans had fixed it!

I’ve also had Claude build an updated .deb package for my rig that includes the fix.