gorgeous-waitress-5026
05/14/2024, 11:43 PMglamorous-carpet-83516
05/16/2024, 5:22 PMglamorous-carpet-83516
05/16/2024, 5:23 PMpyflyte run or register
, the version should be different when you change the code or task config.glamorous-carpet-83516
05/16/2024, 5:24 PMmd5_bytes
is a hash of the source code. https://github.com/flyteorg/flytekit/pull/2417/files#diff-c56afc489e5060224889036253b85ae7c7f1df9f0f7b1130916d9c614293cbb9R1049gorgeous-waitress-5026
05/16/2024, 5:40 PMgorgeous-waitress-5026
05/16/2024, 5:40 PMgorgeous-waitress-5026
05/16/2024, 5:41 PMgentle-umbrella-41187
05/16/2024, 7:49 PMfrom flytekit import task, workflow
@task
def say_hello(name: str) -> str:
return f"Hello, {name}!"
@workflow
def wf() -> str:
import datetime
name = str(datetime.datetime.now())
res = say_hello(name=name)
return res
edit: I think this workflow does not follow Flyte principles, the datetime logic should be extracted into its own task, and then resolved as a promise.