revert: update components filter and build artifact logic (#6022)
This commit is contained in:
parent
492ce82968
commit
e09d3fe0bf
2 changed files with 5 additions and 4 deletions
1
.github/changes-filter.yaml
vendored
1
.github/changes-filter.yaml
vendored
|
|
@ -45,6 +45,7 @@ components:
|
|||
- "src/frontend/tests/extended/integrations/**"
|
||||
- "src/frontend/tests/extended/features/**"
|
||||
- "src/frontend/tests/extended/regression/**"
|
||||
- "src/backend/base/langflow/custom/**"
|
||||
|
||||
workspace:
|
||||
- "src/backend/base/langflow/inputs/**"
|
||||
|
|
|
|||
|
|
@ -957,19 +957,19 @@ class Component(CustomComponent):
|
|||
custom_repr = str(custom_repr)
|
||||
|
||||
raw = self._process_raw_result(result)
|
||||
artifact_type = get_artifact_type(raw or self.status, result)
|
||||
artifact_type = get_artifact_type(self.status or raw, result)
|
||||
raw, artifact_type = post_process_raw(raw, artifact_type)
|
||||
return {"repr": custom_repr, "raw": raw, "type": artifact_type}
|
||||
|
||||
def _process_raw_result(self, result):
|
||||
if hasattr(result, "data"):
|
||||
if self.status:
|
||||
raw = self.status
|
||||
elif hasattr(result, "data"):
|
||||
raw = result.data
|
||||
elif hasattr(result, "model_dump"):
|
||||
raw = result.model_dump()
|
||||
elif isinstance(result, dict | Data | str):
|
||||
raw = result.data if isinstance(result, Data) else result
|
||||
elif self.status:
|
||||
raw = self.status
|
||||
else:
|
||||
raw = result
|
||||
return raw
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue