-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Tweening not working as expected (win 7, Python) #5
Comments
Thanks, I'll take a look at it today. |
Ah, I think I know what the problem is. Is PyAutoGUI updated to the latest version? 0.9.20 In a previous version, PyAutoGUI was set up so that it only expected ranges between 0.0 and 1.0 from the tweening functions. However, the "elastic" and "back up" tweens overshoot the target (for cosmetic effect), and so I rewrote the PyAutoGUI code. Reopen if this bug is present in 0.9.20. Also, what tween were you using? |
Yes, the issue was with 0.9.20 installed with pip, sorry I forgot to add this information in the issue. |
Do you have some code snippets that can reproduce the problem? What exactly is happening? Is the mouse not moving at all? Or is it moving instantly? |
I have tested it at home in a Debian VM, I had to disable cursor integration (Virtualbox) and install a few libraries but the results are the same as what I had in Windows (but I have not tested "elastic" and "back up" tweens). The simplest test case is: import pyautogui pyautogui.moveTo(500, 500, duration=2, tween=pyautogui.tweens.easeInOutQuad) This doesn't work as is (no move at all). |
I'm having a similar issue on Ubuntu, |
I use Ubuntu also, and I get an error when I try it (whether it's python2 or 3).
|
I am also getting this issue, and it's 2016 now. Traceback (most recent call last): Edit, looks like I had to
|
The update to the documentation in 166b828 corrects this. The |
@asweigart Why is this still not fixed in the readme? 🤔 |
Hello,
Tween was not working for me and found that the value tween function was receiving was not within the 0..1 range.
I have not looked further for the why and quickly modified the code to this:
This would probably require a second look and more test before such fix could be submited as a pull request but it's working well for what I need (and I'm a little bit pressured by time).
Thanks for the great library!
Eric
The text was updated successfully, but these errors were encountered: