Python Forum

Full Version: import pynput
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Traceback (most recent call last):
File "C:\python_examples\pynput_2.py", line 1, in <module>
from pynput.mouse import Listener
File "C:\python_examples\pynput.py", line 1, in <module>
from pynput.mouse import Listener
ModuleNotFoundError: No module named 'pynput.mouse'; 'pynput' is not a package

Hallo!

I'm a beginner in python i can't import the pynput library. I get all the time the ModuleNotFound. I have been used pip(pip install pynput), but itsn't work.
Can you help me, please?
Thanks for your help!
Rename your python_examples\pynput.py it shadowing the real import of pynput.
Thanks!