Skip to content Skip to sidebar Skip to footer

Pybluez 'module Object Has No Attribute 'discover_devices'

I'm fairly new to python and I'm trying to get Pybluez to work for me. Here is what happens when i try to discover bluetooth devises. import bluetooth nearby_devices = bluetooth.d

Solution 1:

I had the same problem, I did the mistake of naming my program file bluetooth.py , which confused python for the package resolution, you should look out for this silly mistake if this is the case .

If this is not the case then try to put your file in the directory where your bluetooth directory (in my case, C:\Python27\Lib\site-packages) is located and then run it from there, it worked for me.

Solution 2:

I faced same issue because i have taken my file name bluetooth.py.For that reason python unable to understand which file be execute. Please rename your file then it will be work.

Solution 3:

rename the file to any other name, except "bluetooth.py"

Post a Comment for "Pybluez 'module Object Has No Attribute 'discover_devices'"