--> -->
 
 
OperationalError
Python 3.9.0: /misc/www/projects/tcdb2/tcdb-python/bin/python
Tue Sep 27 07:34:11 2022

A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.

 /misc/www/projects/tcdb2/cgi-bin/projectv/public/families.py in <module>
     28 if __name__=='__main__':
     29         print ('Content-Type: text/plain\n')
=>   30         connection,cursor = tcdb.connect()
     31         query = 'select family,name from family where 1;'
     32         cursor.execute(query)
connection undefined, cursor undefined, tcdb = <module 'tcdb' from '/misc/www/projects/tcdb2/tcdbscripts/scripts/tcdb.py'>, tcdb.connect = <function connect>
 /misc/www/projects/tcdb2/tcdbscripts/scripts/tcdb.py in connect()
      5 
      6 def connect():
=>    7         connection = mysql.connect(host='mysql8.sdsc.edu',port=3313,user='tcdb',passwd='kjcs22y2',db='tcdb2')
      8         cursor = connection.cursor()
      9         return connection,cursor
connection undefined, global mysql = <module 'mysql.connector' from '/misc/www/projec...on3.9/site-packages/mysql/connector/__init__.py'>, mysql.connect = <function connect>, host undefined, port undefined, user undefined, passwd undefined, db undefined
 /misc/www/projects/tcdb2/tcdb-python/lib/python3.9/site-packages/mysql/connector/__init__.py in connect(*args=(), **kwargs={'db': 'tcdb2', 'host': 'mysql8.sdsc.edu', 'passwd': 'kjcs22y2', 'port': 3313, 'user': 'tcdb'})
    269     if HAVE_CEXT and not use_pure:
    270         return CMySQLConnection(*args, **kwargs)
=>  271     return MySQLConnection(*args, **kwargs)
    272 Connect = connect  # pylint: disable=C0103
    273 
global MySQLConnection = <class 'mysql.connector.connection.MySQLConnection'>, args = (), kwargs = {'db': 'tcdb2', 'host': 'mysql8.sdsc.edu', 'passwd': 'kjcs22y2', 'port': 3313, 'user': 'tcdb'}
 /misc/www/projects/tcdb2/tcdb-python/lib/python3.9/site-packages/mysql/connector/connection.py in __init__(self=<mysql.connector.connection.MySQLConnection object>, *args=(), **kwargs={'db': 'tcdb2', 'host': 'mysql8.sdsc.edu', 'passwd': 'kjcs22y2', 'port': 3313, 'user': 'tcdb'})
    105         if kwargs:
    106             try:
=>  107                 self.connect(**kwargs)
    108             except:
    109                 # Tidy-up underlying socket on failure
self = <mysql.connector.connection.MySQLConnection object>, self.connect = <bound method MySQLConnectionAbstract.connect of...sql.connector.connection.MySQLConnection object>>, kwargs = {'db': 'tcdb2', 'host': 'mysql8.sdsc.edu', 'passwd': 'kjcs22y2', 'port': 3313, 'user': 'tcdb'}
 /misc/www/projects/tcdb2/tcdb-python/lib/python3.9/site-packages/mysql/connector/abstracts.py in connect(self=<mysql.connector.connection.MySQLConnection object>, **kwargs={'db': 'tcdb2', 'host': 'mysql8.sdsc.edu', 'passwd': 'kjcs22y2', 'port': 3313, 'user': 'tcdb'})
    983 
    984         self.disconnect()
=>  985         self._open_connection()
    986         # Server does not allow to run any other statement different from ALTER
    987         # when user's password has been expired.
self = <mysql.connector.connection.MySQLConnection object>, self._open_connection = <bound method MySQLConnection._open_connection o...sql.connector.connection.MySQLConnection object>>
 /misc/www/projects/tcdb2/tcdb-python/lib/python3.9/site-packages/mysql/connector/connection.py in _open_connection(self=<mysql.connector.connection.MySQLConnection object>)
    308             self._socket.open_connection()
    309             self._do_handshake()
=>  310             self._do_auth(self._user, self._password,
=>  311                           self._database, self._client_flags, self._charset_id,
=>  312                           self._ssl, self._conn_attrs)
self = <mysql.connector.connection.MySQLConnection object>, self._do_auth = <bound method MySQLConnection._do_auth of <mysql.connector.connection.MySQLConnection object>>, self._user = 'tcdb', self._password = 'kjcs22y2', self._database = 'tcdb2', self._client_flags = 1813005, self._charset_id = 45, self._ssl = {}, self._conn_attrs = {'_client_license': 'GPL-2.0', '_client_name': 'mysql-connector-python', '_client_version': '8.0.22', '_os': 'CentOS Linux-7', '_pid': '33357', '_platform': 'x86_64', '_source_host': 'yolk'}
 /misc/www/projects/tcdb2/tcdb-python/lib/python3.9/site-packages/mysql/connector/connection.py in _do_auth(self=<mysql.connector.connection.MySQLConnection object>, username='tcdb', password='kjcs22y2', database='tcdb2', client_flags=1813005, charset=45, ssl_options={}, conn_attrs={'_client_license': 'GPL-2.0', '_client_name': 'mysql-connector-python', '_client_version': '8.0.22', '_os': 'CentOS Linux-7', '_pid': '33357', '_platform': 'x86_64', '_source_host': 'yolk'})
    217             conn_attrs=conn_attrs)
    218         self._socket.send(packet)
=>  219         self._auth_switch_request(username, password)
    220 
    221         if not (client_flags & ClientFlag.CONNECT_WITH_DB) and database:
self = <mysql.connector.connection.MySQLConnection object>, self._auth_switch_request = <bound method MySQLConnection._auth_switch_reque...sql.connector.connection.MySQLConnection object>>, username = 'tcdb', password = 'kjcs22y2'
 /misc/www/projects/tcdb2/tcdb-python/lib/python3.9/site-packages/mysql/connector/connection.py in _auth_switch_request(self=<mysql.connector.connection.MySQLConnection object>, username='tcdb', password='kjcs22y2')
    274             return self._handle_ok(packet)
    275         elif packet[4] == 255:
=>  276             raise errors.get_exception(packet)
    277         return None
    278 
global errors = <module 'mysql.connector.errors' from '/misc/www...thon3.9/site-packages/mysql/connector/errors.py'>, errors.get_exception = <function get_exception>, packet = bytearray(b'\x1d\x00\x00\x03\xff\x10\x04#08004Too many connections')

OperationalError: 1040 (08004): Too many connections
      args = (1040, '1040 (08004): Too many connections', '08004')
      errno = 1040
      msg = 'Too many connections'
      sqlstate = '08004'
      with_traceback = <built-in method with_traceback of OperationalError object>