I accidentally started “Play Solo” before adding a wait() to a while loop, and Studio ended up freezing my system and causing it to crash. By the time I realized my mistake, my mouse was no longer moving.
This could cause damage to the disk and other hardware, so I’d urgently recommend adding resource limiting and infinite loop detection to prevent causing damage to any dev’s workstation.
Studio would either detect RAM exceeding some threshold or detect that a certain thread has been taking up all the CPU for more than a certain amount of time. Then stop the process gracefully.
How? Studio should at best Stop Responding for a few seconds and then terminate the thread with the loop stating “allowed execution time exhausted”. Nothing gets damaged even on my almost-9 year old laptop.
I mean in the case I mentioned, my laptop started getting very hot and the OS had to kick in to stop everything. Studio didn’t stop the thread itself as you’d expect.
you can lower this in Studio settings to make an indefinitely spinning script stop sooner, in your case you could comfortably set it to 1 second or something
Thank you for the report.
As mentioned, we have an execution time limit that can be configured in Studio settings.
Overall, it is up for the operating system to ensure fair resource usage and sharing between processes and deny requests for more resources from user-level software like Roblox when they are not available and can affect overall system stability.
Systems with pre-emptive multi-tasking like Windows for example, ensure that even when one process tries to use all the CPU time available, the mouse will still operate and Task Manager will be able to close the unresponsive application.
Adding an arbitrary memory limit will not help as we rely on operating system already to provide memory amounts appropriate for the machine.