I’m running into the same issue. The bug sometimes resolves itself, but has come back on and off the past few months. It’s got to the point where it’s really slowing the development of my game down. What was the solution you found?
Trivial computations (such as raycasts) and actions in-game are leading to major lag spikes out of nowhere. There’s been no changes in the scripts nor any backdoors since the issue started again yesterday.
(UPDATE)
It randomly resolved without any changes yet again. If there’s a solution to prevent this from happening in the future, it’d be appreciated.
(UPDATE 2)
Less than 10 minutes later, no changes to scripts, the issue is back.
(UPDATE 3)
I finally fixed it. When mesh parts were directly parented to the workspace it caused lag with anything physics related. After I grouped the mesh parts into a model so that they were no longer directly parented, it solved the issue.