But the thing is that I am not changing or adding any JS code. The site is using the stock JS code that came with the script. The error is triggered by something in my custom modules (though I have seen the error occur even without any custom modules).
I am having the exact same issue... with a recent install of version 2.4.0.
I have tried the Firebug console but doesn't really help much.