marcnewlin / hi_my_name_is_keyboard

BSD 2-Clause "Simplified" License
622 stars 100 forks source link

ModuleNotFoundError: No module named 'dbus' #11

Open kiven7299 opened 6 months ago

kiven7299 commented 6 months ago

Hi there,

I have installed all the required dependencies as mentioned here. However, when I executed the python script "keystroke-injection-android-linux.py", it raised error:

Traceback (most recent call last):
  File "/mnt/d/Tools/hi_my_name_is_keyboard/./keystroke-injection-android-linux.py", line 11, in <module>
    from injector.agent import PairingAgent
  File "/mnt/d/Tools/hi_my_name_is_keyboard/injector/agent.py", line 1, in <module>
    import dbus
ModuleNotFoundError: No module named 'dbus'

I'm using kali wsl. It does have pydbus python package but not dbus. I have tried to install legacy dbus-python package but it failed to install. How to fix this problem? image

Thank you and have a great day!

cobra-c313 commented 5 months ago

Yeah, im having the same issue. After much digging, I have concluded that dbus-python is not working well with python3.10, we have to use a previous version to make it install successfully

kiven7299 commented 5 months ago

Thank you @cobra-c313, which version that you use?

Neowizard commented 2 months ago

You can install python3-dbus using apt. It should resolve your missing dependency issue