def download_blob()

in connectors/blob.py [0:0]


    def download_blob(self):
        """
        Downloads the blob data from Azure Blob Storage.

        Returns:
            bytes: The content of the blob.

        Raises:
            Exception: If downloading the blob fails.
        """
        blob_client = self.blob_service_client.get_blob_client(container=self.container_name, blob=self.blob_name)

        try:
            logging.debug(f"[blob][{self.blob_name}] Attempting to download blob.")
            data = blob_client.download_blob().readall()
            logging.info(f"[blob][{self.blob_name}] Blob downloaded successfully.")
            return data
        except Exception as e:
            logging.error(f"[blob][{self.blob_name}] Failed to download blob: {e}")
            raise Exception(f"Blob client error when reading from blob storage: {e}")