title: Pymysql can't connect do MySQL DB: hangs at "self.sock.recv_into(b)"?
body: <p>Currently on macOS 10.15 using python 3.7, with MySQL 8.0.19 installed. Developing in VScode with a virtual environment setup. I've created a local database in phpmyadmin as well. I want to connect to it anyway possible. Script:</p>
  
  <pre><code>import pymysql
  
  print("Before")
  connection = pymysql.connect(host='localhost',
      user='myUserName', password='myPassword', db='db_name', charset='utf8mb4', 
            cursorclass=pymysql.cursors.DictCursor)
  print("After")
  </code></pre>
  
  <p>When I run the script, execution hangs indefinitely. After printing "After", I have to quit execution. Trackback is:</p>
  
  <pre><code>Traceback (most recent call last):
  File "connect.py", line 5, in &lt;module&gt;
    user='myUserName', password='myPassword', db='db_name', charset='utf8mb4', 
    cursorclass=pymysql.cursors.DictCursor)
  File "/Users/name/Documents/Work/Connection Test/env/lib/python3.7/site- 
    packages/pymysql/__init__.py", line 94, in Connect
    return Connection(*args, **kwargs)
  File "/Users/name/Documents/Work/Connection Test/env/lib/python3.7/site- 
    packages/pymysql/connections.py", line 325, in __init__
    self.connect()
  File "/Users/name/Documents/Work/Connection Test/env/lib/python3.7/site- 
    packages/pymysql/connections.py", line 598, in connect
    self._get_server_information()
  File "/Users/name/Documents/Work/Connection Test/env/lib/python3.7/site- 
    packages/pymysql/connections.py", line 975, in _get_server_information
    packet = self._read_packet()
  File "/Users/name/Documents/Work/Connection Test/env/lib/python3.7/site- 
  packages/pymysql/connections.py", line 657, in _read_packet
    packet_header = self._read_bytes(4)
  File "/Users/name/Documents/Work/Connection Test/env/lib/python3.7/site- 
    packages/pymysql/connections.py", line 691, in _read_bytes
    data = self._rfile.read(num_bytes)
  File "/usr/local/Cellar/python/3.7.6_1/Frameworks/Python.framework/Versions/3.7/lib/
  python3.7/socket.py", line 589, in readinto
    return self._sock.recv_into(b)
  KeyboardInterrupt
  </code></pre>
  
  <p>No idea why this is occurring. What is happening here? I have searched a ton of questions on stack overflow and none helped me. </p>