rootkiwi / an2linuxserver

Sync Android notifications encrypted to a Linux desktop
Other
402 stars 43 forks source link

Cannot use on xUbuntu with bluetooth #31

Open enboig opened 7 years ago

enboig commented 7 years ago

Using Xubuntu 16.04 server fails to start:

./an2linuxserver.py [2017-03-30 14:47:23] Server certificate fingerprint: 7F 38 1C D0 93 14 6F 75 AD A2 E0 4C 6C E0 A7 E3 9F 21 30 AA Traceback (most recent call last): File "/home/myusername/.local/lib/python3.5/site-packages/bluetooth/bluez.py", line 240, in advertise_service protocols) _bluetooth.error: (2, 'No such file or directory')

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "./an2linuxserver.py", line 836, in bluetooth_server = ThreadingBluetoothServer() File "./an2linuxserver.py", line 282, in init profiles=[SERIAL_PORT_PROFILE]) File "/home/myusername/.local/lib/python3.5/site-packages/bluetooth/bluez.py", line 242, in advertise_service raise BluetoothError (str (e)) bluetooth.btcommon.BluetoothError: (2, 'No such file or directory')

I think the problem is between python 2.7, 3.0 and 3.5 I installed using pip: pip3 install pybluez --user

I tried running the script with python 2.7, 3 and 3.5

rootkiwi commented 7 years ago

Hmm, maybe try this? http://stackoverflow.com/a/33141030

Yes, you should use python 3.5 for this because minimum supported is 3.4

ghost commented 6 years ago

Just wanted to chime in and confirm that adding the compatibility flag to (bluetoothd --> bluetoothd --compat) fixed the issue, at least for me.