async def _process_event(
        self,
        client: httpx.AsyncClient,
        event_data: Dict,
        cal_breadcrumb: Breadcrumb,
    ) -> AsyncGenerator[ChunkEntity, None]:
        """Process a single event and its attachments."""
        event_id = event_data["id"]
        event_subject = event_data.get("subject", "No Subject")

        logger.debug(f"Processing event: {event_subject} (ID: {event_id})")

        # Create event entity
        event_entity = self._create_event_entity(event_data, cal_breadcrumb)
        yield event_entity
        logger.debug(f"Event entity yielded for {event_subject}")

        # Create event breadcrumb for attachments
        event_breadcrumb = Breadcrumb(
            entity_id=event_id,
            name=event_subject[:50] if event_subject else f"Event {event_id[:8]}",
            type="event",
        )

        # Process attachments if the event has any
        if event_entity.has_attachments:
            logger.debug(f"Event {event_subject} has attachments, processing them")
            attachment_count = 0
            try:
                async for attachment_entity in self._process_event_attachments(
                    client, event_id, [cal_breadcrumb, event_breadcrumb]
                ):
                    attachment_count += 1
                    logger.debug(
                        f"Yielding attachment #{attachment_count} from event {event_subject}"
                    )
                    yield attachment_entity
                logger.debug(f"Processed {attachment_count} attachments for event {event_subject}")
            except Exception as e:
                logger.error(f"Error processing attachments for event {event_id}: {str(e)}")
Process a single event and its attachments.
backend/airweave/platform/sources/outlook_calendar.py