Page 1 of 1

script: python import error - UPDATE [solved]

Posted: Tuesday 13 March 2018 9:45
by lupo2a
I installed from scratch a with noobs raspbian environment and domoticz 3.8984

in a dzVents script I have the followig line

Code: Select all

suona=os.execute('/usr/bin/python /home/pi/scripts/play_song.py -20 /home/pi/Music/Gabbani_Occidentali.mp3 /home/pi/scripts/log/test.txt 0 >/home/pi/scripts/log/test_err.txt 2>&1 &')
When the script runs In the test_err.txt there is the following error

Code: Select all

Traceback (most recent call last):
  File "/home/pi/scripts/play_song.py", line 3, in <module>
    import rxv
ImportError: No module named rxv
If I log in with usr pi and run the same command line it works.

Any help?

UPDATE 20180314
It look like the item is related to the fact that, despite the definition of USERNAME=pi in domoticz.sh, the domoticz process is owned by root
I installed the rxv module as root and it works