Skip to content
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

ValueError() with pynput 1.3.2 on FreeBSD 11 #29

Closed
neelchauhan opened this issue Jun 3, 2017 · 1 comment
Closed

ValueError() with pynput 1.3.2 on FreeBSD 11 #29

neelchauhan opened this issue Jun 3, 2017 · 1 comment

Comments

@neelchauhan
Copy link

When I try to run pynput 1.3.2 (from pip) on FreeBSD 11.0 amd64, I get this error:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/neel/.local/lib/python2.7/site-packages/pynput/mouse/_base.py", line 78, in scroll
    self._scroll(dx, dy)
  File "/home/neel/.local/lib/python2.7/site-packages/pynput/mouse/_xorg.py", line 75, in _scroll
    self._check_bounds(dx, dy)
  File "/home/neel/.local/lib/python2.7/site-packages/pynput/mouse/_xorg.py", line 103, in _check_bounds
    raise ValueError()
ValueError

The commands I am trying to run include:

from pynput.mouse import Controller
Controller().scroll(0, 1)

Please advise

@moses-palmer
Copy link
Owner

Thank you for your report.

The issue was caused by an invalid condition: a while ago, a check was added to ensure that values were valid short ints; unfortunately the check was inverted.

I have made a new release, 1.3.4, which fixes the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants