mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-10-03 19:57:35 +00:00
pre-commit FML
This commit is contained in:
parent
f676c48a97
commit
3b7982c59f
1 changed files with 1 additions and 1 deletions
|
@ -567,7 +567,7 @@ def get_class_properties(typ: type) -> Iterable[Tuple[str, type | str]]:
|
|||
|
||||
if is_dataclass_type(typ):
|
||||
return ((field.name, field.type) for field in dataclasses.fields(typ))
|
||||
elif hasattr(typ, 'model_fields'):
|
||||
elif hasattr(typ, "model_fields"):
|
||||
# Pydantic BaseModel - use model_fields to exclude ClassVar and other non-field attributes
|
||||
# Reconstruct Annotated type if discriminator exists to preserve metadata
|
||||
from typing import Annotated
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue