fix: add memo to deepcopy call to avoid recursion error (#4194)
Fix deepcopy bug by passing memo to deepcopy calls in custom component
This commit is contained in:
parent
e4e1e1bd86
commit
12476648f8
2 changed files with 3 additions and 3 deletions
|
|
@ -138,8 +138,8 @@ class Component(CustomComponent):
|
|||
def __deepcopy__(self, memo):
|
||||
if id(self) in memo:
|
||||
return memo[id(self)]
|
||||
kwargs = deepcopy(self.__config)
|
||||
kwargs["inputs"] = deepcopy(self.__inputs)
|
||||
kwargs = deepcopy(self.__config, memo)
|
||||
kwargs["inputs"] = deepcopy(self.__inputs, memo)
|
||||
new_component = type(self)(**kwargs)
|
||||
new_component._code = self._code
|
||||
new_component._outputs_map = self._outputs_map
|
||||
|
|
|
|||
2
uv.lock
generated
2
uv.lock
generated
|
|
@ -3632,7 +3632,7 @@ dev = [
|
|||
[package.metadata]
|
||||
requires-dist = [
|
||||
{ name = "assemblyai", specifier = ">=0.33.0" },
|
||||
{ name = "astra-assistants", specifier = ">=2.2.2" },
|
||||
{ name = "astra-assistants", specifier = "~=2.2.2" },
|
||||
{ name = "beautifulsoup4", specifier = ">=4.12.2" },
|
||||
{ name = "boto3", specifier = "~=1.34.162" },
|
||||
{ name = "cassio", marker = "extra == 'cassio'", specifier = ">=0.1.7" },
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue