Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

不能直接拿来运行吗?错误信息如下 #3

Open
TanHudong opened this issue May 15, 2017 · 0 comments
Open

不能直接拿来运行吗?错误信息如下 #3

TanHudong opened this issue May 15, 2017 · 0 comments

Comments

@TanHudong
Copy link

Traceback (most recent call last):
File "D:/workspace/Python/spiderWanghong/huajiao.py", line 137, in
class BoseModel(Model):
File "D:/workspace/Python/spiderWanghong/huajiao.py", line 138, in BoseModel
conn = Mysql(host='127.0.0.1', unix_socket='/tmp/mysql.sock', user='root', passwd='123456', db='wanghong', charset='utf8')
File "D:\workspace\Python\spiderWanghong\mysql.py", line 14, in new
cls.connect(**params)
File "D:\workspace\Python\spiderWanghong\mysql.py", line 22, in connect
cls.conn = pymysql.connect(**params)
File "D:\IDE\Python\Python36\lib\site-packages\pymysql_init_.py", line 90, in Connect
return Connection(*args, **kwargs)
File "D:\IDE\Python\Python36\lib\site-packages\pymysql\connections.py", line 706, in init
self.connect()
File "D:\IDE\Python\Python36\lib\site-packages\pymysql\connections.py", line 903, in connect
sock = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
AttributeError: module 'socket' has no attribute 'AF_UNIX'

Process finished with exit code 1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant