Weird code copying

I’ve seen this happen 3 times in my classes this week. A whole bunch of code is randomly copied into the same buffer. Since I couldn’t verify exactly what keystrokes the students had just used, I can’t locate the cause. But it happened last year as well.

Has anyone ever seen this happen? I’m using 2.7 on the Pi.

Help!
Bob Irving

Could you share which code was added?

Unfortunately, she doesn’t remember exactly what code she added, but she said it was something very simple. If this helps, here is her code, post-doubling and cleanup:

live_loop :beats do
sleep 0.25
sleep 0.25
sample :tabla_ghe3
sample :elec_wood, cutoff: 90
sleep 0.25
end
use_bpm 20
live_loop :pop do
sample :elec_plip, amp: 2
sleep 0.25
end
live_loop :drums do
sample :elec_wood, cutoff: 90
sleep 0.25
sample :elec_tick
sleep 0.25
end
live_loop :continuing do
use_bpm 10
sample :loop_mika, amp: 0.3
sleep 0.75
end
live_loop :chords do
#stop
use_synth :piano
sync :pop
sleep 0.1
play chord(:a4, :major), release: 0.5, amp: 0.3
end

live_loop :chords2 do
#stop
use_synth :piano
sync :pop
sleep 0.25
play chord(:c5, :major), release: 0.5, amp: 0.4
sleep 0.75
end

I have noticed (probably) the same behaviour. While working with several live_loops I suddenly had a copy of these in the same buffer (I did notice this because at sometime there was an additional sound which confused me as all live_loops except one were on hold).

I will try to figure out if I can find something reproducable but this seems to be quite difficult.

I am currently running a selfcompiled Sonic Pi 3.2 on Linux.

1 Like

So I’m not crazy…:smiley:

Well, that’s still to be confirmed… maybe we are both crazy :wink:

1 Like

I do it on the Pi in my class, though I use Windows 10. I’ve never seen it happen in Windows but it happens with some regularity on the Pi. Hmm…

Hmm. Still happening on my Raspberry Pi Sonic Pi installs. Multiple lines of code get duplicated randomly into other live loops. So frustrating. I love Sonic Pi and my students are really starting to get it, so I would love for this not to happen!

Sorry your’e having issues, but until we can find a reliable way to reproduce this, there’s not much I can do about it. Perhaps recording it on video might be possible?

1 Like

I have noticed something like this before. I think it has occurred when I have had a fairly large before (near to the limit), and have copy and pasted text within the buffer. I have subsequently found the buffer contests a bit scrambled. I don’t think I found a reproducible scenario, but I think buffer capacity may be related.

1 Like

I will try to video it, but it’s so random that it’s hard to do that. And it doesn’t seem to be connected to large buffers. I actually watched it this week as a student was working on his code. Unfortunately, I didn’t see every keystroke he did so I couldn’t troubleshoot it that way.