asweigart / pyscreeze

PyScreeze is a simple, cross-platform screenshot module for Python 2 and 3.
BSD 3-Clause "New" or "Revised" License
194 stars 96 forks source link

Crash after random amount of sequences of looping pyatuogui.pixelMatchesColor(x, y, (R, G, B)) #72

Open FeronFae opened 3 years ago

FeronFae commented 3 years ago

Every time I run my script, I get an error at a random point in time (the program can crash on startup or minutes into running) that says windll.user32.ReleaseDC failed : return 0. I read up on this issue thread made a while back and read it was "implemented" into the code, yet on Python 3.9.1 it simply does not seem to work, yet I tried running it on a separate Kernel (one that is not directly in cmd and thus runs the script I designed quite slowly [for reference, it's the built-in Kernel of Spyder 3.7]) with Python 3.7.6 and it seems to work perfectly fine. At this point, I have no clue what could be causing this issue nor how to fix it; any updates or help would be appreciated.

JustinG7164 commented 3 years ago

,me too