Work Around for Midi Out problem

Summary: when sending midi out Sonic Pi gives the error:

" NoMethodError
Thread death +--> :live_loop_md
 undefined method `send_ts'; for nil:NilClass
Did you mean?  send"


I had a frustrating bug creep in today (using Windows 10, Sonic Pi 3.1RC1) that is the same issue posted here by @sub_repeat [Midi out problem](http://Midi Out Problem)

What is odd is that I have not had problems with Midi using the exact same code. This morning it was working fine. During a break I installed a Demo version of I could not get Sundog to send midi to FL Studio and while trouble shooting I lost the ability to send Midi from Sonic Pi, instead getting the above error message.

I tried fixing the Sonic Pi install, reinstalling Sonic Pi, and uninstalling Sundog with no sucesss

Workaround - @JosephWilk to the rescue!!!

Searching on the internet I came across this post on the Sonic Pi repo: Following his suggestion I pasted the code into the buffer that I was evaluating and it worked!! (YMMV):

@osc_server ||=, use_decoder_cache: true) #__nosave__


  • Would the software that I installed conflict with Sonic Pi somehow?
  • I’d love to better understand what this fix is doing.
  • Does this patch give any of the Sonic Pi ninjas a bead on what the larger issue might be?
  • I am open to any suggestions on how I can help test/troubleshoot this

Hope this helps someone!!

1 Like

My hacked code to the rescue :slight_smile:

Port 4559 is the server_osc_cues server:

I suspect this is to do with the handshake when everything starts up. That handshake outside of the main GUI is a slightly misty path. I never use the Qt SP GUI. By ensuring the OSC server is running we get past the handshake.

Programming music is full of procrastination for me, writing code rather than music. Since this has worked perfectly for me for the last year and has never failed me in a live concert I’ve not investigated it.

If this is really causing you bother than I’ll be motivated to look into it more deeply. If you would like some help investigating I could help. Otherwise a little bit of duct tape around the edges is nothing out of the ordinary in a music setup :slight_smile: