4

I'm using Skype4Py with Python 3.2.3 on windows. There was an error while trying to import Skype4Py package and I did the following to figure out what it was:

import sys

try:
   import Skype4Py
except:
   print (sys.exc_info()[0])
   print (sys.exc_info()[1])

The output is as follows:

<class 'Import error'>

No module named skype

I installed Skype4Py with the windows installer. I can see the Skype4Py in Python32\Lib\site-packages. How do I get this to work?

bala_88
  • 391
  • 1
  • 3
  • 14
  • Try this `from Skype4Py import Skype` and see if it works. Although I am able to use both `from Skype4Py import Skype` and `import Skype4Py` but I am using python-2.x. – RanRag Sep 05 '12 at 18:12
  • 5
    It seems like it is [not supported on python 3.x](https://developer.skype.com/skypekit/reference/python/html/help.html). – RanRag Sep 05 '12 at 18:17
  • Hey thanks for pointing that out. Will have to work out something else. – bala_88 Sep 05 '12 at 18:30
  • What you did above with the try except is to hide the traceback, and instead just print part of it. That is not going to tell you *more* about what is wrong. :-) – Lennart Regebro Sep 06 '12 at 06:03
  • @Lennart Regebro, python noob here. First piece of code I've written in py. Thanks, will keep that in mind. – bala_88 Sep 06 '12 at 06:16

2 Answers2

4

It is clearly stated in the Skype Dev Page that :

The Python wrapper is compatible and is tested with Python version 2.6.5 - Python versions 3.x are not supported at this time.

guess its bad luck then,

I reckon that skype dev's had given up the SkypeKit Python Wrapper Reference due to lack of ...

but

you can find a independently maintained version of skype4py at Github though it also only works in python 2.x versions, it's updated regularly and, It has a far bigger community than the skype maintained project which is nearly dead and also supports latest 2.x versions rather than only supporting 2.6.5. here you can find the Documentation for using the github maintained version of skype4py Skype4py usage

K DawG
  • 13,287
  • 9
  • 35
  • 66
1

Your issue ( I just found out the same thing ) is the the installer is written for Python 2 - so you didn't really install it, wasn't fully installed. So api will not work!!!

File "C:\Users\PETER_~1\AppData\Local\Temp\pip_buil

print 'zipping the documentation'

                               ^

SyntaxError: Missing parentheses in call to 'print'

print 'zipping the documentation'

No () around print is a Python 2 issue. You could rewrite the installer I guess but the basic problem is Skype API is built on PYTHON 2 - if you need Python 3 as I do, no luck!!

OhBeWise
  • 5,350
  • 3
  • 32
  • 60