This simple piece of code crashes (the window is not responding) after a few seconds (around 5).
import pygame from pygame.locals import * pygame.init() sc
Call pygame.event.get() at the beginning of the while loop.
pygame.event.get()