Open linxcow opened 1 year ago
Hi @linxcow,
Thanks for reporting this. It made me realise that the documentation is not clear enough.
Indeed, when installing ProbeQuest via pip3 install --upgrade probequest
, the entry point is placed in ~/.local/bin/probequest
(/home/pi/.local/bin/probequest
in your case), and the Python modules in ~/.local/lib
. The problem comes from the fact that ProbeQuest requires root privileges to sniff raw Wi-Fi packets, and that the Python interpreter cannot locate ProbeQuest's dependencies when run with a different user than the one used to install ProbeQuest.
In a previous version of the documentation, users were instructed to install ProbeQuest with the root user via sudo pip3 install --upgrade probequest
, but this was a bad practice as it "may interfere with the operation of the system package manager and other components of the system if a component is unexpectedly upgraded using pip" as stated in the Python documentation. This is why I removed the "sudo" prefix from the installation command-line in the documentation but I forgot to update the rest of the instructions.
From the top of my head, I can see two workarounds:
PYTHONPATH
environment variable: sudo PYTHONPATH=/home/pi/.local/lib/python3.9/site-packages/ /home/pi/.local/bin/probequest
Use a dedicated virtual environment:
# Create a new virtual environment.
python -m venv .probequest-venv
# Enter the virtual environment.
source .probequest-venv/bin/activate
# Install ProbeQuest inside the virtual environment.
pip install probequest
# Leave the virtual environment.
deactivate
# Run ProbeQuest installed inside the virtual environment via sudo.
sudo .probequest-venv/bin/probequest
I acknowledge that this is not ideal but I will try to find a better way. In all cases, I will update the installation instructions in the documentation.
I used the method described in the online help to install using pip3
I set the wifi card in monitor mode ( checked using iw wlan info)
after launching i get following messages
platform Python 3.9