Skip to main content

ensure_multipart_is_installed

Ensures that a compatible version of the python-multipart or multipart library is installed. If neither is found or the installed version is incompatible, it raises a RuntimeError.

def ensure_multipart_is_installed() - > None

Ensures that the python-multipart library is correctly installed and meets the minimum version requirement. This function checks for the presence of the python-multipart library and verifies its version, or falls back to checking the multipart library if python-multipart is not found or is an older version. Callers should use this to confirm that the necessary multipart parsing capabilities are available before proceeding with operations that rely on them.

Returns

TypeDescription
NoneThis function does not return any value. It raises a RuntimeError if the required multipart library is not installed or is incorrectly configured.