Fix typing and minor issues
This commit is contained in:
parent
2db2253578
commit
72ab627a34
54 changed files with 635 additions and 589 deletions
|
|
@ -25,10 +25,10 @@ class Trace(Generic[T], HashableBaseModel):
|
|||
extra = Extra.ignore
|
||||
|
||||
@validator("trace_id", always=True)
|
||||
def generate_id(cls, v: Optional[str], values: Dict[str, Any]) -> Optional[str]:
|
||||
if not v:
|
||||
return str(uuid4())
|
||||
return v
|
||||
def generate_id(cls, v: Optional[str], values: Dict[str, Any]) -> str:
|
||||
if v:
|
||||
return v
|
||||
return str(uuid4())
|
||||
|
||||
@property
|
||||
def input(self) -> Any:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue