2012.08.17 11:37

root@ubuntu:~/k1rha/python/http# python blind.py

Traceback (most recent call last):

  File "blind.py", line 1, in <module>

    import urllib.request

  File "/usr/lib/python3.2/urllib/request.py", line 88, in <module>

    import http.client

  File "/usr/lib/python3.2/http/client.py", line 69, in <module>

    import email.parser

  File "/usr/lib/python3.2/email/parser.py", line 12, in <module>

    from email.feedparser import FeedParser

  File "/usr/lib/python3.2/email/feedparser.py", line 27, in <module>

    from email import message

  File "/usr/lib/python3.2/email/message.py", line 17, in <module>

    from email import utils

  File "/usr/lib/python3.2/email/utils.py", line 28, in <module>

    import socket

  File "/root/k1rha/python/http/socket.py", line 7, in <module>

    s = socket.socket(socket.AF_INET,socket.SOCK_STREAM)

AttributeError: 'module' object has no attribute 'AF_INET'

root@ubuntu:~/k1rha/python/http# 

위와같인 에러가 떴을때 아래와 같은 결과를 얻을수 있었다. 

h I found the problem, it seems I cant run socket things from my home folder ... I moved the script into a new folder and it worked.

Thanks.


즉 폴더에 소켓생성권한이 없기떄문에 다른 폴더로 옮겨 실행했다는 내용이다 필자도 비슷하게 해결봄.

Posted by k1rha