henningw left a comment (kamailio/kamailio#4169)
Thanks for the report. From the linked commit it looks that the dialog is already deleted for some reasons. As you stated, if the BYE is only send in one direction, maybe the dialog is already deleted during the first BYE send out, and depending on the exact timing, its then not send out to the other party. This would be a race condition, the dialog should be only deleted after the second BYE was send out (just guessing right now, have not checked the code).