def release(self, connection):
        "Releases the connection back to the pool"
        self._checkpid()
        if connection.pid != self.pid:
            return
        self._in_use_connections.remove(connection)
        self._available_connections.append(connection)
Releases the connection back to the pool
stackoverflow/venv/lib/python3.6/site-packages/redis/connection.py