No idea why it crashes, wp. That's why I shared that bit of code, so you cld try it and see for yourselves.
You say it works on Windows. I haven't tried there yet, but I will. I'm coding this on Linux Mint 21, where the error's encountered. Thanks for the heads up on Windows, though.
And this really isn't even abt Random(); it's abt catching an error when thrown. While this might not throw an error on Windows, it does on Linux Mint, as seen in the above image. I say it's Random() only because I can change count := 0 to count := 1 and it doesn't error. So I just wanted to know if I was using the try/except the correct way. As for the error I'm getting, I already have that fixed. But I'd rather rely on the try/catch block.