monome / norns

norns is many sound instruments.
http://monome.org
GNU General Public License v3.0
630 stars 145 forks source link

scsynth crashes when switching engines, sometimes #371

Closed catfact closed 6 years ago

catfact commented 6 years ago

weoul dbe great to narrow this down more.

is it only some engines?

destructor in a custom ugen?

something bad in a sclang class (free method?)

&c.

let's see if we can get some data points...

artfwo commented 6 years ago

typically happens when restarting scripts from maiden (either same or different engine).

catfact commented 6 years ago

if script defines engine.name, then `engine.load is called https://igithub.com/catfact/norns/blob/dev/lua/script.lua#L81

sends OSC and triggers this in sclang: https://github.com/catfact/norns/blob/dev/sc/core/Crone.sc#L69

calls engine superclass deinit from a fork: https://github.com/catfact/norns/blob/dev/sc/core/CroneEngine.sc#L42

which assumes subclass implements free (maybe bad assumption) and also subclass shouldn't call super.free anymore i think...

catfact commented 6 years ago

one question is, can we ever reproduce something like this on a non-norns system running same sclang code

pq commented 6 years ago

typically happens when restarting scripts from maiden

this has been my experience. tonight in particular, w/ 16sliders.

catfact commented 6 years ago

oh man, 16sliders is even broken in other ways. when i hit key2 the screen drawing stops (though everything else works.) this is literally the simplest script / engine and has been working for months and months

artfwo commented 6 years ago

i had the crash with all polysub-based scripts and step (ack-based)

pq commented 6 years ago

oh man, 16sliders is even broken in other ways.

i think i fixed that: https://github.com/tehn/dust/commit/28d611c08231eb2afcf1cd447c2d786aa473358f

tehn commented 6 years ago

be sure to pull newest dust, i fixed the redraw error a couple days ago

tehn commented 6 years ago

we should look into alsa overruns, but i'm going to close this for now