def circuitOpened(self, circuit):
        '''Circuits call circuitOpened() when they have successfully
        completed their build process and are ready to handle incoming
        streams.

        When a circuit opens, CircuitManager:

            - removes it from the pending circuit map
            - adds it to the open circuit map
            - assigns any pending requests that this circuit can handle to
              this freshly opened circuit
            - if this is the first circuit successfully opened, send a nice
              message to the user letting them know oppy is ready to forward
              traffic

        :param oppy.circuit.circuit.Circuit circuit: circuit that
            has just opened.
        '''
        msg = ("Circuit manager notified that circuit {} opened."
               .format(circuit.circuit_id))
        logging.debug(msg)

        try:
            del self._circuit_build_task_dict[circuit.circuit_id]
        except __HOLE__:
            msg = ("Circuit manager has no reference to circuit {}."
                   .format(circuit.circuit_id))
            logging.debug(msg)
            return

        self._open_circuit_dict[circuit.circuit_id] = circuit
        self._assignPossiblePendingRequestsToCircuit(circuit)
        self._notifyUserCircuitOpened()
dataset/ETHPy150Open nskinkel/oppy/oppy/circuit/circuitmanager.py/CircuitManager.circuitOpened