Hi all, We are using the example for warm transfe...
# telephony
e
Hi all, We are using the example for warm transfer here, using this example we have created a warm transfer agent which is working as expected. The issue that we are facing is that upon successfull transfer when the merge calls functions is called the agent is still present in the room. While removing the agent from room using lkapi the room is closed and the entire call ends.
👍 1
r
Why are you removing all the participants in the room if you want them to stay in the room?
lkapi.room.remove_participant(api.RoomParticipantIdentity...
a
We are not removing all the participants but only the agent from the room
Copy code
for participant in participants.participants:
                logger.info(f"participant {participant.identity} in customer room")
                if participant.identity in [_supervisor_identity, self.caller_participant.identity]:
                    logger.info(f"keeping participant {participant.identity} in customer room")
                else:
                    logger.info(f"removing participant {participant.identity} from customer room")
                    self.customer_room.emit("participant_disconnected", participant)
c
@refined-appointment-81829 I have a similar transfer-related bug that appeared recently after upgrading livekit-agents. I used to use
self.ctx.shutdown()
to kick out only the agent while keeping the other participants in the room. Now, I see the event "Participant Left (ROMM_DELETED)" in the LIvekit Cloud Dashboard for all participants. My understanding is that shutting down the context is not supposed to remove all the participants.
r
I agree that it should not remove all participants. I will look into it.
c
Thanks, that's because the room is deleted automatically after the shutdown hook is completed. It doesn't occur in
1.2.9
r
c
Yes, thanks. I was not setting it and was tricked by the change of default value.