Python not starting

Mark Lawrence breamoreboy at yahoo.co.uk
Sun May 5 10:26:58 EDT 2013


On 05/05/2013 15:00, DRJ Reddy wrote:
> On Sunday, May 5, 2013 7:21:59 PM UTC+5:30, Roy Smith wrote:
>> In article <9ace60b8-a07d-41bc-ac9f-507f6c61f955 at googlegroups.com>,
>>
>>   rama29065 at gmail.com wrote:
>>
>>> I was using python from over an year and half.Suddenly from yesterday i'm
>>> unable to run it.
>>> The error is as follows
>>
>>> Traceback (most recent call last):
>>>    File "C:\Python27\lib\site.py", line 563, in <module>
>>>      main()
>>>    File "C:\Python27\lib\site.py", line 546, in main
>>>      known_paths = addsitepackages(known_paths)
>>>    File "C:\Python27\lib\site.py", line 324, in addsitepackages
>>>      if os.path.isdir(sitedir):
>>>    File "C:\Python27\lib\genericpath.py", line 44, in isdir
>>>      return stat.S_ISDIR(st.st_mode)
>>> AttributeError: 'module' object has no attribute 'S_ISDIR'
>>
>> Just a wild guess, but did you happen to create a module of your own
>> named "stat", which is getting imported instead of the one from the
>> library?
>>
>> Try doing:
>>>>> print stat.__file__
>>
>> and see what it says.
>
> Even from command prompt i can't start python.The error is coming up.Python in Windows7 box.
>

Place the call to print stat.__file__ in the file genericpath.py 
immediately before the line that gives the attribute error.

Would you also be kind enough to read and use the guidance given in the 
link in my signature.  My eyesight is bad enough without parsing double 
spaced stuff courtesy of google groups, thanks.

-- 
If you're using GoogleCrap™ please read this 
http://wiki.python.org/moin/GoogleGroupsPython.

Mark Lawrence




More information about the Python-list mailing list