mirror of
https://github.com/hwchase17/langchain.git
synced 2025-07-14 08:56:27 +00:00
fix: bump min_unstructured_version for UnstructuredAPIFileLoader (#11025)
**Description:** New metadata fields were added to `unstructured==0.10.15`, and our hosted api has been updated to reflect this. When users call `partition_via_api` with an older version of the library, they'll hit a parsing error related to the new fields.
This commit is contained in:
parent
75b3893daf
commit
bb41252dab
@ -253,10 +253,7 @@ class UnstructuredAPIFileLoader(UnstructuredFileLoader):
|
|||||||
):
|
):
|
||||||
"""Initialize with file path."""
|
"""Initialize with file path."""
|
||||||
|
|
||||||
if isinstance(file_path, str):
|
validate_unstructured_version(min_unstructured_version="0.10.15")
|
||||||
validate_unstructured_version(min_unstructured_version="0.6.2")
|
|
||||||
else:
|
|
||||||
validate_unstructured_version(min_unstructured_version="0.6.3")
|
|
||||||
|
|
||||||
self.url = url
|
self.url = url
|
||||||
self.api_key = api_key
|
self.api_key = api_key
|
||||||
|
Loading…
Reference in New Issue
Block a user