You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Refactor 4 different renderings of task description (#3743)
Prior to this PR, there were 4 variant ways to render a future (which is
usually but not always a Parsl task) as a text string:
1. describing failure of inner future in a join_app with 1 future to
join
- rendered task ID if the inner future has a task record attribute,
without checking it is a parsl.dataflow.taskrecord.TaskRecord or that
that attribute contains a task id entry.
- otherwise render as None
2. describing failure of inner future in a join_app with a list of
futures to join
- is meant to do the same as case 1, but is buggy and always renders as
None (the wrong object is checked for having a task_record attribute)
3. describing failure of a dependency future
- rendered task ID if there was a task_record, and the
future is from the same DFK as is rendering the code
(so that a task number from a different DFK is not
rendered, in the corner case of a task from one DFK
being used as a dependency for a task in another DFK)
- otherwise, renders the repr of the future
4. describing which dependencies will be waited on when submitting a
task to the DFK
- rendered task ID if the future is an instance of AppFuture or
DataFuture
- otherwise renders the repr of the future
This PR makes a single render method. It is a member of the DFK, because
rendering is done in the context of the DFK: two parsl task AppFutures
will be rendered differently if they are from this DFK or a different
DFK.
This PR implements render_future_description which tries to combine all
of the above:
- if the future is an AppFuture, and is from the same
DFK, render the task ID
- otherwise render the repr of the future
# Changed Behaviour
human readable descriptions of dependencies/join inner futures will be
changed
# Fixes
Fixes # (issue)
## Type of change
Choose which options apply, and delete the ones which do not apply.
- Bug fix
- New feature
- Update to human readable text: Documentation/error messages/comments
- Code maintenance/cleanup
0 commit comments