automatically do guess type
This commit is contained in:
parent
96e5181e14
commit
612274900a
@ -536,8 +536,10 @@ class Component(BaseComponent, ABC):
|
||||
if isinstance(value, Var):
|
||||
if isinstance(value, EventChainVar):
|
||||
return value
|
||||
if isinstance(value, EventVar):
|
||||
elif isinstance(value, EventVar):
|
||||
value = [value]
|
||||
elif isinstance(value._var_type, (EventChain, EventSpec)):
|
||||
return self._create_event_chain(args_spec, value.guess_type())
|
||||
else:
|
||||
raise ValueError(
|
||||
f"Invalid event chain: {str(value)} of type {value._var_type}"
|
||||
|
Loading…
Reference in New Issue
Block a user