flytekit icon indicating copy to clipboard operation
flytekit copied to clipboard

fix: Fix to consider /union-persist-data files as remote files so they can be used as inputs to FlyteRemote

Open ggydush opened this issue 1 year ago • 0 comments

Tracking issue

n/a

Why are the changes needed?

Using persist files with FlyteRemote execute does not work current.

What changes were proposed in this pull request?

Consider files prefixed with /union-persistent-data to be "remote"

How was this patch tested?

  1. Create a task that accepts FlyteFile
@task
def dummy_task(ff: FlyteFile) -> FlyteFile:
   return ff
  1. Call this with FlyteRemote
from flytekit.remote.remote import FlyteRemote

remote = FlyteRemote()
task = "dummy_task"
inputs = {
    "ff": "/union-persistent-data/..."
}
task = remote.fetch_task(name=task)
remote.execute(task, inputs=inputs)

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

ggydush avatar May 16 '24 18:05 ggydush