C:\Users\Amr\PycharmProjects\pythonProject_1\venv\Scripts\python.exe "C:/Users/Amr/PycharmProjects/pythonProject_1/Test_التعامل مع قواعد البيانات في بايثون.py"
Traceback (most recent call last):
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\network.py", line 509, in open_connection
self.sock.connect(sockaddr)
ConnectionRefusedError: [WinError 10061] No connection could be made because the target machine actively refused it
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\Amr\PycharmProjects\pythonProject_1\Test_التعامل مع قواعد البيانات في بايثون.py", line 5, in <module>
db = mysql.connector.connect(
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\__init__.py", line 179, in connect
return MySQLConnection(*args, **kwargs)
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\connection.py", line 95, in __init__
self.connect(**kwargs)
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\abstracts.py", line 716, in connect
self._open_connection()
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\connection.py", line 206, in _open_connection
self._socket.open_connection()
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\network.py", line 511, in open_connection
raise errors.InterfaceError(
mysql.connector.errors.InterfaceError: 2003: Can't connect to MySQL server on 'localhost:3306' (10061 No connection could be made because the target machine actively refused it)
Process finished with exit code 1
وصف المشكلة:
تم اضافة الحزمة mysql-connector في بايثون وتم التثبيت بنجاح
لكن مع عمل اول مشروع مع الحزمة تم ظهور الخطأ السابق.. عندما قرأته اعتقدت ان المشكلة مع Firewall .. وقمت بالسماح له بالتصال من خلاله .. لكن المشكلة لم تكن كما توقعت ..
السؤال
Amr Eddesoky
نص المشكلة من البرنامج ..
C:\Users\Amr\PycharmProjects\pythonProject_1\venv\Scripts\python.exe "C:/Users/Amr/PycharmProjects/pythonProject_1/Test_التعامل مع قواعد البيانات في بايثون.py"
Traceback (most recent call last):
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\network.py", line 509, in open_connection
self.sock.connect(sockaddr)
ConnectionRefusedError: [WinError 10061] No connection could be made because the target machine actively refused it
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\Amr\PycharmProjects\pythonProject_1\Test_التعامل مع قواعد البيانات في بايثون.py", line 5, in <module>
db = mysql.connector.connect(
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\__init__.py", line 179, in connect
return MySQLConnection(*args, **kwargs)
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\connection.py", line 95, in __init__
self.connect(**kwargs)
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\abstracts.py", line 716, in connect
self._open_connection()
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\connection.py", line 206, in _open_connection
self._socket.open_connection()
File "C:\Users\Amr\PycharmProjects\pythonProject_1\venv\lib\site-packages\mysql\connector\network.py", line 511, in open_connection
raise errors.InterfaceError(
mysql.connector.errors.InterfaceError: 2003: Can't connect to MySQL server on 'localhost:3306' (10061 No connection could be made because the target machine actively refused it)
Process finished with exit code 1
وصف المشكلة:
تم اضافة الحزمة mysql-connector في بايثون وتم التثبيت بنجاح
لكن مع عمل اول مشروع مع الحزمة تم ظهور الخطأ السابق.. عندما قرأته اعتقدت ان المشكلة مع Firewall .. وقمت بالسماح له بالتصال من خلاله .. لكن المشكلة لم تكن كما توقعت ..
2 أجوبة على هذا السؤال
Recommended Posts
انضم إلى النقاش
يمكنك أن تنشر الآن وتسجل لاحقًا. إذا كان لديك حساب، فسجل الدخول الآن لتنشر باسم حسابك.