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

pymysql.err.OperationalError: (2003, "Can't connect to MySQL server on 'localhost' #6

Open
JACKGELOVE opened this issue Jul 11, 2023 · 0 comments

Comments

@JACKGELOVE
Copy link

运行python chatdb.py后报错

ConnectionRefusedError: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:
pymysql.err.OperationalError: (2003, "Can't connect to MySQL server on 'localhost' ([Errno 111] Connection refused)")

File "/home/Documents/git_clone/ChatDB/mysql.py", line 59, in execute_sql
self.conn.rollback()
AttributeError: 'NoneType' object has no attribute 'rollback'

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