I've come to believe this is more a problem with my laptop than with RahiTube itself. The same glitch happened with Vegas Pro 14 after rendering a video. No clue why still, but I doubt there's anything wrong with your code ¯\_(ツ)_/¯
Thanks for the update, good luck finding the solution!