socket.py and 2.2.1

TeaAndBikkie teaandbikkie at aol.com
Fri Nov 8 18:49:33 EST 2002


>From: susan at provis.com  (Susan Williams)
>
>Hello,
>
>We're finally getting around to upgrading from 1.5.2 to 2.2.1... ;-)
>and I'm having a problem (Solaris 5.7).
>
>I've got the simple (no SSL) socketmodule in my python, and
>when I try to import the socket module I get the following error:
>
>>python
>Python 2.2.1 (#6, May 24 2002, 16:38:14) [C] on sunos5
>Type "help", "copyright", "credits" or "license" for more information.
>>>> import socket
>Traceback (most recent call last):
>  File "<stdin>", line 1, in ?
>  File "/usr/local/lib/python2.2/socket.py", line 47, in ?
>    __all__.extend(os._get_exports_list(_socket))
>AttributeError: 'module' object has no attribute '_get_exports_list'
>>>> 
>
>Yup, the source line is there all right, and socket.py and the os
>module seem to be on different planets.  Anyone got a clue what
>is hosed up here?

Perhaps you have an old version of socket.pyc in your Lib directory? Try
deleting (or renaming) socket.pyc and see if the error disappears.

Kind regards,
Misha



More information about the Python-list mailing list