1

I am on Mac OSX (10.8.2) and am trying to use Skype4py to connect to my currently running Skype instance via Python.

My difficulty here is that I have followed the instructions on the website (http://pypi.python.org/pypi/Skype4Py/1.0.34#segfaults), and properly installed Skype4Py using the arch -i386 pip install Skype4Py command. As the instructions state, I have set my code editor's run code to use the arch -i386 python command to run things instead of the typical python (As well as tried using both to run the file directly from terminal).

My code is currently really simple (I plan to work further once I get the connection working), and is as follows:

import Skype4Py
skype = Skype4Py.Skype()
skype.Attach()

That gives me an error window that python had to close as well as the following error: Run Command: line 1: 66888 Segmentation fault: 11 arch -i386 python "$1" "${@:3}"

After some searching around on these forums, I had found a few threads that agree upon the following code revision as an answer:

import Skype4Py
skype = Skype4Py.Skype(Transport='x11')
skype.Attach()

Unfortunately, this fix simply changes the nature of my error. The new error message is more complicated:

Traceback (most recent call last):
  File "skypeAttach.py", line 4, in <module>
    skype = Skype4Py.Skype(Transport='x11')
  File "build/bdist.macosx-10.8-intel/egg/Skype4Py/skype.py", line 250, in __init__
  File "build/bdist.macosx-10.8-intel/egg/Skype4Py/api/darwin.py", line 296, in __init__
  File "build/bdist.macosx-10.8-intel/egg/Skype4Py/api/__init__.py", line 214, in finalize_opts
TypeError: Unexpected option(s): Transport

Which, under my limited programming knowledge, seems to be trying to tell me that "Transport" is an unexpected parameter.

  • Try running it with `python-32` instead. – nneonneo Feb 05 '13 at 12:36
  • @nneonneo `Run Command: line 1: python-32: command not found` .. I also have since tried `arch -i386 /usr/bin/python2.6` Which leads to the error of: `No module named Skype4Py` – user2042859 Feb 05 '13 at 12:53
  • Hm? `python-32` should be in `/Library/Frameworks/Python.framework/Versions/2.x/bin`; it comes with the python.org distribution of Python (which I recommend using). – nneonneo Feb 05 '13 at 12:57
  • @nneonneo I used the installer found at python.org/download titled "Python 3.3.0 Mac OS X 64-bit/32-bit x86-64/i386 Installer." And I don't have the "2.x" folder in my Versions folder, only the "3.3.0" folder. – user2042859 Feb 05 '13 at 13:11
  • @nneonneo I am going to try version 2.7, now. – user2042859 Feb 05 '13 at 13:12

2 Answers2

1

From the Skype4Py PyPI page:

It works on Windows, OSX and Linux platforms with Python 2.x versions.

It is not compatible with Python 3.3. Try installing it with Python 2.7.

nneonneo
  • 171,345
  • 36
  • 312
  • 383
1

I ended up using a shell script to force 32-bit mode:

#!/bin/bash
arch -i386 /usr/bin/python ./sendMessage.py