Skip to content

Commit

Permalink
Single-task execution FlyteRemote sync (#778)
Browse files Browse the repository at this point in the history
Signed-off-by: Yee Hing Tong <wild-endeavor@users.noreply.github.com>
  • Loading branch information
wild-endeavor committed Dec 14, 2021
1 parent f0c8ab8 commit 9e77e62
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions flytekit/remote/remote.py
Original file line number Diff line number Diff line change
Expand Up @@ -1117,6 +1117,14 @@ def sync_node_execution(
"""
# For single task execution - the metadata spec node id is missing. In these cases, revert to regular node id
node_id = execution.metadata.spec_node_id
# This case supports single-task execution compiled workflows.
if node_id and node_id not in node_mapping and execution.id.node_id in node_mapping:
node_id = execution.id.node_id
remote_logger.debug(
f"Using node execution ID {node_id} instead of spec node id "
f"{execution.metadata.spec_node_id}, single-task execution likely."
)
# This case supports single-task execution compiled workflows with older versions of admin/propeller
if not node_id:
node_id = execution.id.node_id
remote_logger.debug(f"No metadata spec_node_id found, using {node_id}")
Expand Down

0 comments on commit 9e77e62

Please sign in to comment.