fix: make sure graph build errors bubble up to the frontend (#5864)
fix: Add handling for None value in validate_source method to return default Source instance
This commit is contained in:
parent
cdf85e55de
commit
4ff34b6cc9
1 changed files with 2 additions and 0 deletions
|
|
@ -28,6 +28,8 @@ class Properties(BaseModel):
|
|||
def validate_source(cls, v):
|
||||
if isinstance(v, str):
|
||||
return Source(id=v, display_name=v, source=v)
|
||||
if v is None:
|
||||
return Source()
|
||||
return v
|
||||
|
||||
@field_serializer("source")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue