cuddly-jelly-27016
06/30/2025, 12:11 AMmessage and a failed_node_id. Given that the name of the field is failed_node_id and not failure_node_id, I would expect the value to have the id of the failed node/task instead of the (current) failure_node.
### Expected behavior
When printing/accessing a `FlyteError`s failed_node_id field in a Failure Node task, I expect to get the failed node id. Not the id of the failure node.
A big nice to have would be to actually get the Task ID in addition to the node id as this gives more context than just the node id.
### Additional context to reproduce
Based on documentation example
from flytekit import task, workflow
import typing
@task
def t1():
raise ValueError("Fail!")
@task
def clean_up(name: str, err: typing.Optional[FlyteError] = None):
print(f"Deleting cluster {name} due to {err.message} in {err.failed_node_id}") # Expected it to be n0, but is instead fn0
@workflow(on_failure=clean_up)
def wf(name: str):
t1()
### Screenshots
No response
### Are you sure this issue hasn't been raised already?
• Yes
### Have you read the Code of Conduct?
• Yes
flyteorg/flytecuddly-jelly-27016
06/30/2025, 12:11 AM