Skip to content

Backend

Media backend availability exception family.

MediaBackendUnavailableError(*, backend=None, next_step=None, debug_info=None)

Bases: ComponentError, RuntimeError

Report a missing media component needed by the selected backend.

Use this during setup when a selected backend cannot run because its executable or required library is unavailable.

Example

A processor selects FFmpeg, but FFmpeg is not installed.

from gllm_multimodal.exceptions import MediaBackendUnavailableError

error = MediaBackendUnavailableError(backend="FFmpeg")
print(error.message)
Output:
The selected FFmpeg backend is unavailable. Check that it is installed, or select another backend.

Initialize the error with backend context and recovery guidance.

Parameters:

Name Type Description Default
backend str | None

Name of the unavailable backend, if known. Defaults to "media".

None
next_step str | None

Suggested recovery action. Defaults to checking the backend installation or selecting another backend.

None
debug_info DebugInfo | None

Optional diagnostic context, sanitized before storage.

None