asweigart / pyautogui

A cross-platform GUI automation Python module for human beings. Used to programmatically control the mouse & keyboard.
BSD 3-Clause "New" or "Revised" License
10.45k stars 1.26k forks source link

mouse failure sometimes #714

Open jack-ylt opened 2 years ago

jack-ylt commented 2 years ago

mouse failure sometimes

Description: I use pyautogui to play game. Most time, it works very well. but, sometimes, the pyautogui can't contrl the mouse and keyboard. can't move, can't click, can't tap keys...

Analysis:

  1. After mouse failure, if move the mouse manually, the failure will be restore.
  2. It occurs randomly. I run the code about 2 hours a day. sometimes, the failure occurs after dozens of minutes. sometimes, it work well for several weeks without any failure
  3. My pc info: win10 64bit 16 GB ram 1 TB disk windows 10 firewall opened
jack-ylt commented 2 years ago

the logs: image

SamiTesla commented 2 years ago

Mind sharing your code?