-
Notifications
You must be signed in to change notification settings - Fork 245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pymouse / PyMouseEvent .run() doesn't resume function after .stop() is called #117
Comments
Same issue! Maybe xlib had some updates which broke pymouse. (Here the related issue) For some reason it gets stuck in the context manager. I'm currently not sure what display2 is needed for but commenting:
works. But if you are using a loop which reruns an already created PyMouseEvent object (when initializing from scratch then it works) I get the following error thrown:
Has maybe something to do with not closing display2 correctly. Any help would be appreciated. Thanks! |
I faced a cpu-hungry behavior when stop() is called. This is due to being stucked in the while loop in
with Btw the issue seems the EDIT: From client side I can avoid this behavior overriding stop() like this:
I have obviously to import the modules i need:
|
This project is no longer mainteined btw. Use https://github.com/moses-palmer/pynput instead EDIT: just faced the same issue with pynput because this is a platform dependent problem. |
This is a linux machine.
This was working 3/4 years ago when I wrote it and now it's buggy.
Then in my main program:
This is how it was and it was running fine in previous versions.
When I clicked with button 1 it would set the value, correctly and when I clicked middle or button 2, it would resume the python script or, go back to prompt.
Now it gets stuck.
if I put prints on the "if button ==1" then and else. It does capture mouse events until I press any other button. But then it gets stuck until ctrl+c is pressed many many times.
if I switch to
It comes back to the python shell but value was never defined because it runs in the background and proceeds right away.
Am I doing something wrong that doesn't match most recent versions? Thanks
The example with clickonacci has the exact same problem, anything I can do?
The text was updated successfully, but these errors were encountered: