Load the blob from a path like object.
from_path(
cls,
path: AnyPath,
*,
encoding: str = 'utf-8',
mime_type: Optional[str] = None,
guess_type: bool = True,
metadata: Optional[dict] = None
) -> Blob| Name | Type | Description |
|---|---|---|
path* | AnyPath | path like object to file to be read Supports s3://, az://, gs://, file:// schemes. If no scheme is provided, it is assumed to be a local file. |
encoding | str | Default: 'utf-8'Encoding to use if decoding the bytes into a string |
mime_type | Optional[str] | Default: Noneif provided, will be set as the mime-type of the data |
guess_type | bool | Default: TrueIf True, the MIME type will be guessed from the file extension, if a mime-type was not provided |
metadata | Optional[dict] | Default: NoneMetadata to associate with the blob |