Closed kelvinlouis closed 11 years ago
Hello! This could happen if you are trying to run swvabot from terminal, which has not DISPLAY variable:
DISPLAY=:0
export DISPLAY
Or you can connect via VNC, and run shell - issue should be solved.
I tried setting the DISPLAY variable to 0 or 1 and I still got the same issue. I read in a couple of other places that there are issues with Skype4Py and latest Ubuntu versions.
Hm.. Strange. Have you tried starting application from VNC, when X daemon is running?
I just noticed that I wasn't running the commands with the skype user. I set export DISPLAY=:1
and I got the following messages:
(venv)skype@server:~/sevabot$ sevabot
Starting sevabot
Discovered module ping: /home/skype/sevabot/modules/ping.sh
Discovered module sad: /home/skype/sevabot/modules/sad.py
Discovered module timeout: /home/skype/sevabot/modules/timeout.sh
Discovered module memoryhog: /home/skype/sevabot/modules/memoryhog.sh
Discovered module soundcloud: /home/skype/sevabot/modules/soundcloud.rb
Discovered module weather: /home/skype/sevabot/modules/weather.py
Skype API connection established
opened
Attaching to Skype
thread started
sending u'#0 NAME Skype4Py'
received u'#0 CONNSTATUS OFFLINE'
attachment: 2
Traceback (most recent call last):
File "/home/skype/sevabot/venv/bin/sevabot", line 8, in <module>
load_entry_point('sevabot==1.1.dev0', 'console_scripts', 'sevabot')()
File "/home/skype/sevabot/sevabot/frontend/main.py", line 139, in entry_point
exit_code = plac.call(main)
File "/home/skype/sevabot/venv/local/lib/python2.7/site-packages/plac-0.9.1-py2.7.egg/plac_core.py", line 309, in call
cmd, result = parser_from(obj).consume(arglist)
File "/home/skype/sevabot/venv/local/lib/python2.7/site-packages/plac-0.9.1-py2.7.egg/plac_core.py", line 195, in consume
return cmd, self.func(*(args + varargs + extraopts), **kwargs)
File "/home/skype/sevabot/sevabot/frontend/main.py", line 89, in main
sevabot.start()
File "/home/skype/sevabot/sevabot/bot/bot.py", line 34, in start
self.skype.Attach()
File "build/bdist.linux-i686/egg/Skype4Py/skype.py", line 408, in Attach
File "build/bdist.linux-i686/egg/Skype4Py/api/posix_x11.py", line 386, in attach
File "build/bdist.linux-i686/egg/Skype4Py/api/__init__.py", line 163, in set_attachment_status
File "build/bdist.linux-i686/egg/Skype4Py/skype.py", line 35, in attachment_changed
Skype4Py.errors.SkypeAPIError: Skype connection refused
thread finished
closed
I tried to login via echo accname pw | skype --pipelogin
, before running sevabot
, but that didn't work.
Any idea why I can't connect to skype?
Sounds like you are not allowing "External programs to control Skype" in Skype UI preferences
Do you know if there is a way to set this without using the UI? I'm running on a terminal only server.
Please read installation instructions for headless server:
https://sevabot-skype-bot.readthedocs.org/en/latest/ubuntu.html#setting-up-skype-and-remote-vnc
Hey guys,
After installing sevabot and trying to run it, I got the following messages:
Any idea why this is happening? Is something wrong with Skype4Py?
Thanks Kelvin