pyautogui: pyautogui does not interact with the mouse

I created a stackoverflow question about this here, but it seems no one has any solutions to my problem. The linked post has the details and visually shows the issue I am having, but the basic problem is that pyautogui is not moving my visual mouse pointer. Additionally, when I run a script, moving my mouse to the top left corner does not stop the script. Strangely, the script still works as long as I do not move my mouse, as if the library is interacting with an invisible mouse.

What is going wrong and how might I fix it?

I am running Ubuntu 18.04 LTS, and it is essentially a fresh install. Please see my link to the stackoverflow question for the photo example and more detail.

About this issue

  • Original URL
  • State: open
  • Created 6 years ago
  • Comments: 20 (1 by maintainers)

Most upvoted comments

Try to run the Python IDLE as Admin.

It seems that after you install the pyautogui and its following packages, you should restart the computer. At first my pyautogui on my ubuntu doesn’t read pixel nor interact with mouse. But after restarting, now it works like a charm