{"record":{"id":"30db96df1be96d6a","repo":"BerriAI/litellm","slug":"cloud-storage-bucket-name-is-required","errorCode":null,"errorMessage":"Cloud storage bucket name is required","messagePattern":"Cloud storage bucket name is required","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"litellm/litellm_core_utils/cloud_storage_security.py","lineNumber":89,"sourceCode":"\n\ndef _validate_cloud_object_path(object_name: str) -> None:\n    if not object_name:\n        raise ValueError(\"Cloud storage object name is required\")\n    if object_name.startswith(\"/\"):\n        raise ValueError(\"Cloud storage object name must be relative\")\n    if any(ord(char) < 32 or ord(char) == 127 for char in object_name):\n        raise ValueError(\"Cloud storage object name contains control characters\")\n    segments: Final = object_name.split(\"/\")\n    if any(segment in {\".\", \"..\"} for segment in segments):\n        raise ValueError(\"Cloud storage object name contains an invalid path segment\")\n    if \"\" in segments[:-1]:\n        raise ValueError(\"Cloud storage object name contains an invalid path segment\")\n\n\ndef split_configured_cloud_bucket_name(bucket_name: str) -> tuple[str, str]:\n    if not isinstance(bucket_name, str) or not bucket_name.strip():\n        raise ValueError(\"Cloud storage bucket name is required\")\n\n    bucket_name = bucket_name.strip()\n    if \"://\" in bucket_name or \"?\" in bucket_name or \"#\" in bucket_name:\n        raise ValueError(\"Cloud storage bucket name must not include a URI scheme or query\")\n    if any(ord(char) < 32 or ord(char) == 127 for char in bucket_name):\n        raise ValueError(\"Cloud storage bucket name contains control characters\")\n\n    bucket, _, prefix = bucket_name.partition(\"/\")\n    if not bucket:\n        raise ValueError(\"Cloud storage bucket name is required\")\n    if \"\\\\\" in bucket:\n        raise ValueError(\"Cloud storage bucket name contains an invalid separator\")\n\n    prefix = prefix.strip(\"/\")\n    if prefix:\n        _validate_cloud_object_path(prefix)\n\n    return bucket, prefix","sourceCodeStart":71,"sourceCodeEnd":107,"githubUrl":"https://github.com/BerriAI/litellm/blob/77b7c6c40c0c5aa5fbcb1d6a1825ac39ca8829b8/litellm/litellm_core_utils/cloud_storage_security.py#L71-L107","documentation":"Validation in split_configured_cloud_bucket_name: the configured bucket name is missing or whitespace-only, so there is no bucket to split into bucket/prefix for cloud storage operations.","triggerScenarios":"Thrown at litellm/litellm_core_utils/cloud_storage_security.py:89 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Configure a non-empty bucket name for cloud storage.","Set the storage bucket in your proxy config / environment."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"77b7c6c40c0c5aa5fbcb1d6a1825ac39ca8829b8","analyzedAt":"2026-08-18T11:44:31.656Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}