Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Support for dynamic and nested workflows. #326

Merged
merged 50 commits into from
Mar 14, 2022
Merged

Conversation

jsonporter
Copy link
Contributor

This change includes support for a number of tickets including both dynamic workflows as well as support for n-depth nested workflows. Additionally, this release includes a version update of React Flow. While this is currently built against a React Flow pre-release version we will be updating once the major version (10.0.0) is released in the near future.

Includes:

  • Support for dynamic nodes
  • Support for nested graphs (n-depth)
  • Added fixed scroll for "view all" versions and increased graph canvas size.
  • Minor performance fixes on parsing.

Type

  • Bug Fix
  • Feature
  • Plugin

Are all requirements met?

  • Code completed
  • Smoke tested
  • Unit tests added
  • Code documentation added
  • Any pending items have an associated Issue

Complete description

Includes React Flow pre-release 10.0.0-next.30 as the new version supports nested graphs (read: subworkflows). More can be found here: https://github.com/wbkd/react-flow

Tracking Issues

https://github.com/flyteorg/flyteconsole/issues/297
https://github.com/flyteorg/flyteconsole/issues/295
https://github.com/flyteorg/flyteconsole/issues/301

Follow-up issue

NA

progress

progress

progress

Saving progress on bounds mapping

progress

progress

progress - nested positions working

progress, nested click working - checking nested-nested-nested

probably want to revert this

nvm moving ahead, saving before wiring up to props

progress, good rollback point

Progress

Progress - top level parents now rendering children

Nested view works for any level, now working to add click events

progress

progress

progress

progress

progress

progress

progress

pre refactor checkin

Progress

progress

progress

progress

progress
@@ -77,13 +85,30 @@ export const getWorkflowId = (workflow: CompiledWorkflow): string => {
return workflow.template.id.name;
};

export const createWorkflowNodeFromDynamic = dw => {
// workflowNode: WorkflowNode
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: remove comment

src/server.tsx Outdated
@@ -28,6 +28,7 @@ export default function serverRenderer({
const isDev = env === 'development';
const isProd = env === 'production';
let html = '';
console.log('init server:');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: remove log

anrusina
anrusina previously approved these changes Mar 11, 2022
Copy link
Contributor

@anrusina anrusina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unit test fix is needed

Signed-off-by: Jason Porter <jason@union.ai>
Signed-off-by: Jason Porter <jason@union.ai>
Signed-off-by: Jason Porter <jason@union.ai>
Signed-off-by: Jason Porter <jason@union.ai>
@codecov
Copy link

codecov bot commented Mar 14, 2022

Codecov Report

Merging #326 (def2028) into master (9216a06) will decrease coverage by 1.53%.
The diff coverage is 22.62%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #326      +/-   ##
==========================================
- Coverage   66.43%   64.89%   -1.54%     
==========================================
  Files         390      390              
  Lines        8746     8990     +244     
  Branches     1571     1626      +55     
==========================================
+ Hits         5810     5834      +24     
- Misses       2936     3156     +220     
Impacted Files Coverage Δ
src/client.tsx 0.00% <0.00%> (ø)
src/components/Entities/EntityDetails.tsx 0.00% <0.00%> (ø)
src/components/Entities/EntityVersions.tsx 0.00% <0.00%> (ø)
src/components/Workflow/StaticGraphContainer.tsx 0.00% <0.00%> (ø)
src/components/Workflow/WorkflowVersionDetails.tsx 0.00% <0.00%> (ø)
src/components/WorkflowGraph/WorkflowGraph.tsx 0.00% <0.00%> (ø)
...s/flytegraph/ReactFlow/ReactFlowGraphComponent.tsx 0.00% <0.00%> (ø)
...mponents/flytegraph/ReactFlow/ReactFlowWrapper.tsx 0.00% <0.00%> (ø)
...ents/flytegraph/ReactFlow/customNodeComponents.tsx 0.00% <0.00%> (ø)
...flytegraph/ReactFlow/transformDAGToReactFlowV2.tsx 0.00% <0.00%> (ø)
... and 17 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 50b5ef5...def2028. Read the comment docs.

anrusina
anrusina previously approved these changes Mar 14, 2022
Copy link
Contributor

@anrusina anrusina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGtm

Copy link
Contributor

@anrusina anrusina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm

@flyte-bot
Copy link
Collaborator

🎉 This PR is included in version 0.44.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants