HuJohner / homebridge-appletv

Apache License 2.0
22 stars 7 forks source link

Error: spawn atvscript ENOENT #15

Open FezVrasta opened 1 year ago

FezVrasta commented 1 year ago

I'm getting this when I start the plugin:

5/28/2023, 11:07:39 AM] Error: spawn atvscript ENOENT
    at Process.ChildProcess._handle.onexit (node:internal/child_process:283:19)
    at onErrorNT (node:internal/child_process:476:16)
    at processTicksAndRejections (node:internal/process/task_queues:82:21)

from the homebridge terminal, both atvremote and atvscript are working correctly.

DSimeone1989 commented 1 year ago

Same here - unfortunately

raroul commented 1 year ago

To summarize pyatv needs to be installed with sudo in order to be used by the homebridge plugin. To do so you need to tweak the rust installation as well. This was the answer for me https://github.com/HuJohner/homebridge-appletv/issues/1#issuecomment-1437417803

FezVrasta commented 1 year ago

I didn't install Rust to get pyatv running. Also, why sudo? I would like to keep ever under the Homebridge user

raroul commented 1 year ago

I didn't install Rust to get pyatv running. Also, why sudo? I would like to keep ever under the Homebridge user

I'm not sure but as mentioned here https://github.com/HuJohner/homebridge-appletv/issues/1#issuecomment-1437244565 Homebridge doesn’t seem to have access to pyatv without a sudo installation. Personally I had to install the Rust compiler and make it accessible to sudo as explained to make everything work. I'm on Raspberry Pi 4

FezVrasta commented 1 year ago

I have a custom script through cmd4 that can access pyatv just fine though.