File tree 1 file changed +6
-8
lines changed 1 file changed +6
-8
lines changed Original file line number Diff line number Diff line change @@ -176,17 +176,15 @@ def from_dict(
176
176
177
177
try :
178
178
instance = component_from_dict (component_class , component_data , name , callbacks )
179
- except Exception as error :
179
+ except Exception as e :
180
180
msg = (
181
- f"Couldn't deserialize component '{ name } ' of class '{ component_class .__name__ } ' because of:"
182
- f"{ error } "
183
- "Component was deserialized with the following data:"
184
- f"{ str (component_data )} ."
185
- "Possible reasons include malformed serialized data, mismatch between the serialized component "
186
- "and the loaded one (due to a breaking change, see "
181
+ f"Couldn't deserialize component '{ name } ' of class '{ component_class .__name__ } ' "
182
+ f"with the following data: { str (component_data )} . Possible reasons include "
183
+ "malformed serialized data, mismatch between the serialized component and the "
184
+ "loaded one (due to a breaking change, see "
187
185
"https://github.com/deepset-ai/haystack/releases), etc."
188
186
)
189
- raise DeserializationError (msg ) from error
187
+ raise DeserializationError (msg ) from e
190
188
pipe .add_component (name = name , instance = instance )
191
189
192
190
for connection in data .get ("connections" , []):
You can’t perform that action at this time.
0 commit comments