recording: work around invalid locale in caption events

This is a workaround for #19178 - but it does not fix the issue. The
caption recording events with invalid empty `<locale/>` are simply
dropped with a warning message, to allow the recording and any valid
caption streams present to be processed.
This commit is contained in:
Calvin Walton 2024-02-06 16:13:39 -05:00
parent b22a9d0c8b
commit 34f8cf30ba

View File

@ -383,6 +383,11 @@ def parse_events(directory="."):
have_record_events = True have_record_events = True
elif name == "EditCaptionHistoryEvent": elif name == "EditCaptionHistoryEvent":
parse_caption_edit(event, element) parse_caption_edit(event, element)
if event["locale"] is None:
logger.warn(
"Skipping invalid caption event with unset locale. See https://github.com/bigbluebutton/bigbluebutton/issues/19178 for details"
)
continue
else: else:
logger.debug("Unhandled event: %s", name) logger.debug("Unhandled event: %s", name)
continue continue