File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -326,7 +326,7 @@ def _exclude_doclist(
326326 from docarray .array .any_array import AnyDocArray
327327
328328 type_ = self ._get_field_annotation (field )
329- if isinstance (type_ , type ) and issubclass (type_ , AnyDocArray ):
329+ if isinstance (type_ , type ) and safe_issubclass (type_ , AnyDocArray ):
330330 doclist_exclude_fields .append (field )
331331
332332 original_exclude = exclude
Original file line number Diff line number Diff line change @@ -192,7 +192,7 @@ def python_type_to_db_type(self, python_type: Type) -> Any:
192192 AbstractTensor : DataType .FLOAT_VECTOR ,
193193 }
194194
195- if issubclass (python_type , ID ):
195+ if safe_issubclass (python_type , ID ):
196196 return DataType .VARCHAR
197197
198198 for py_type , db_type in type_map .items ():
@@ -665,7 +665,7 @@ def find_batched(
665665 if search_field :
666666 if '__' in search_field :
667667 fields = search_field .split ('__' )
668- if issubclass (self ._schema ._get_field_annotation (fields [0 ]), AnyDocArray ): # type: ignore
668+ if safe_issubclass (self ._schema ._get_field_annotation (fields [0 ]), AnyDocArray ): # type: ignore
669669 return self ._subindices [fields [0 ]].find_batched (
670670 queries ,
671671 search_field = '__' .join (fields [1 :]),
You can’t perform that action at this time.
0 commit comments