flytekit icon indicating copy to clipboard operation
flytekit copied to clipboard

WIP - Lazy Evaluation

Open pingsutw opened this issue 1 year ago • 1 comments

Tracking issue

NA

Why are the changes needed?

What changes were proposed in this pull request?

How was this patch tested?

from flytekit import task, workflow


@task(container_image="cr.flyte.org/flyteorg/flytekit:py3.10-1.13.0", retries=5, enable_deck=True)
def say_hello() -> str:
    return "Hello, World!"


@workflow
def wf():
    t1 = say_hello()
    t2 = say_hello().with_overrides(cache=True)
    print("t1: ", t1)  # start running t1 here
    print("t2: ", t2)  # start running t2 here

Setup process

Screenshots

Check all the applicable boxes

  • [ ] I updated the documentation accordingly.
  • [ ] All new and existing tests passed.
  • [ ] All commits are signed-off.

Related PRs

Docs link

pingsutw avatar Dec 14 '24 00:12 pingsutw

Need to handle the case of the "dangling" node, i.e. how to force the evaluation of nodes that are not an upstream dependency of the graph.

eapolinario avatar Dec 18 '24 15:12 eapolinario