def _set_connection(self, connection):
        try:
            self._connection = weakref.proxy(connection)
            self._connection._protocol
        except (AttributeError, __HOLE__):
            raise errors.InterfaceError(errno=2048)
dataset/ETHPy150Open appnexus/schema-tool/schematool/mysql/connector/cursor.py/MySQLCursor._set_connection