go-task / task

A task runner / simpler Make alternative written in Go
https://taskfile.dev
MIT License
11.58k stars 618 forks source link

Can't call "spd-say" when use the Snapcraft version? #282

Closed testautomation closed 4 years ago

testautomation commented 4 years ago

Executing below task

    speak:
        desc: TEXT TO SPEECH
        cmds:
          - spd-say "Robot is ready! Check the results!"

results in the following error

$ task speak
spd-say "Robot is ready! Check the results!"
Failed to connect to Speech Dispatcher:
Error: Can't connect to unix socket /run/user/1000/snap.task/speech-dispatcher/speechd.sock: 
No such file or directory. Autospawn: Autospawn failed.
Speech Dispatcher refused to start with error code, stating this as a reason: 
task: Failed to run task "speak": exit status 1

Additional information

$ screenfetch
                          ./+o+-       osboxes@osboxes
                  yyyyy- -yyyyyy+      OS: Ubuntu 19.10 eoan (VirtualBox VM on Windows 10)
               ://+//////-yyyyyyo      Kernel: x86_64 Linux 5.3.0-26-generic
           .++ .:/++++++/-.+sss/`      Uptime: 2h 40m
         .:++o:  /++++++++/:--:/-      Packages: 1597
        o:+o+:++.`..```.-/oo+++++/     Shell: bash 5.0.3
       .:+o:+o/.          `+sssoo+/    Resolution: 2219x2030
  .++/+:+oo+o:`             /sssooo.   DE: GNOME 
 /+++//+:`oo+o               /::--:.   WM: GNOME Shell
 \+/+o+++`o++o               ++////.   WM Theme: Adwaita
  .++.o+++oo+:`             /dddhhh.   GTK Theme: Yaru [GTK2/3]
       .+.o+oo:.          `oddhhhh+    Icon Theme: Yaru
        \+.++o+o``-````.:ohdhhhhh+     Font: Ubuntu 11
         `:o+++ `ohhhhhhhhyo++os:      CPU: Intel Core i5-9300H @ 4x 2.4GHz
           .o:`.syhhhhhhh/.oo++o`      GPU: svgadrmfb
               /osyyyyyyo++ooo+++/     RAM: 1876MiB / 5803MiB
                   ````` +oo+++o\:    
                          `oo++.   

# installed from snap
$ task --version
Task version: 2.8.0
andreynering commented 4 years ago

Hi @testautomation,

To me, this seems more like a problem with the tool you're trying to call than with Task itself (but I may be wrong!).

Can you please try running that command outside Task to see if it works?

If so, since you installed it using Snapcraft, could you try using one of the precompiled binaries as a sanity check?

testautomation commented 4 years ago

Can you please try running that command outside Task to see if it works?

It does work

osboxes@osboxes:~/projects/my/ehrbase/tests$ spd-say "Robot is ready! Check the results!"
osboxes@osboxes:~/projects/my/ehrbase/tests$ spd-say "Robot is ready! Check the results!"
osboxes@osboxes:~/projects/my/ehrbase/tests$ spd-say "Robot is ready! Check the results!"

could you try using one of the precompiled binaries as a sanity check?

WORKS :) when installed from .deb package

ThanX!

andreynering commented 4 years ago

Sounds like a problem with the Snap version, then.

I'll take a look once it's possible.