Laura Vaida
02/12/2021, 8:48 AMINFO - prefect.FlowRunner | Flow run FAILED: some reference tasks failed.
does somebody know, what might be a reason for that?ale
02/12/2021, 8:56 AMLaura Vaida
02/12/2021, 10:20 AMale
02/12/2021, 10:47 AMLaura Vaida
02/12/2021, 11:23 AMLaura Vaida
02/12/2021, 11:23 AMwith Flow("billwerk-contracts") as flow:
BW_Client_Id = PrefectSecret("BW_Client_id")
BW_Username= PrefectSecret("BW_Username")
BW_Password = PrefectSecret("BW_Password")
BW_Client_Secret = PrefectSecret("BW_Client_Secret")
oauth(client_id = BW_Client_Id, username = BW_Username, password = BW_Password, client_secret = BW_Client_Secret)
flow.run(executor=executor)
flow.storage= Docker(registry_url="<http://gcr.io/keller-steering-enabling/flows|gcr.io/keller-steering-enabling/flows>")
flow.run_config = KubernetesRun()
flow.register('Billwerk')
ale
02/12/2021, 11:29 AMLaura Vaida
02/12/2021, 11:29 AMale
02/12/2021, 11:30 AMLaura Vaida
02/12/2021, 11:30 AMLaura Vaida
02/12/2021, 11:30 AMale
02/12/2021, 11:31 AMflow.register
you are register them either in Prefect Server or Prefect Cloud 🙂
Both of them expose logs of flow runs, you should be able to get them from the UILaura Vaida
02/12/2021, 11:31 AMale
02/12/2021, 11:33 AMLaura Vaida
02/12/2021, 11:55 AMLaura Vaida
02/12/2021, 11:56 AMale
02/12/2021, 11:57 AMLaura Vaida
02/12/2021, 11:58 AMale
02/12/2021, 12:01 PMAmanda Wee
02/12/2021, 12:17 PMuse_local_secrets = true
by default:
https://github.com/PrefectHQ/prefect/blob/master/src/prefect/config.toml
You have to set this to be false
say using a user-defined config file or an env var in order for the secret to be searched for in Prefect Cloud if it is not available locally.Laura Vaida
02/12/2021, 12:21 PMAmanda Wee
02/12/2021, 12:22 PMAmanda Wee
02/12/2021, 12:24 PM$HOME/.prefect/config.toml
with the content:
[cloud]
use_local_secrets = false
Laura Vaida
02/12/2021, 1:41 PMZanie
backend.toml
file is used by the Prefect library for automated config changes e.g. prefect backend cloud
will write to the backend.toml
whereas the config.toml
is for users to configure the library directly.Zanie
Zanie
Laura Vaida
02/12/2021, 4:37 PMLaura Vaida
02/12/2021, 4:37 PM@task
def inc(x):
return x + 1
@task
def dec(x):
return x - 1
@task
def add(x, y):
return x + y
@task
def list_sum(arr):
return sum(arr)
with Flow("dask-example") as flow:
incs = inc.map(x=range(100))
decs = dec.map(x=range(100))
adds = add.map(x=incs, y=decs)
total = list_sum(adds)
flow.run(executor=executor)
flow.storage= Docker(registry_url="<http://gcr.io/keller-steering-enabling/flows|gcr.io/keller-steering-enabling/flows>")
flow.run_config = KubernetesRun()
flow.register('tutorial')