https://prefect.io logo
c

Charles Lariviere

01/06/2021, 9:37 PM
Hey folks 👋 I have a Kubernetes agent deployed on EKS with the
prefect agent kubernetes install
command. I’m running into
ImportError
when trying to run a flow that uses the
SnowflakeQuery
Prefect task.
Copy code
Failed to load and execute Flow's environment: ImportError('Using `prefect.tasks.snowflake` requires Prefect to be installed with the "snowflake" extra.')
I’m wondering where I should specify the dependencies for this flow? I understand that if I was using the
Docker
storage I would define those in
python_dependencies
, but I’m not sure where I should define those without using the
Docker
storage.
The Flow has the following config:
Copy code
...
from prefect.tasks.snowflake import SnowflakeQuery
 
config = {
    "executor": LocalExecutor(),
    "run_config": KubernetesRun(),
    "storage": S3(bucket="BUCKET", secrets=["AWS_CREDENTIALS"])
}
...
j

josh

01/06/2021, 9:43 PM
Hi @Charles Lariviere in order to get the snowflake dependency at runtime you will need to either use Docker storage w/ that dependency or create your own base image that contains both prefect and the snowflake dependency so it can be set in your
KubernetesRun(image="…")
c

Charles Lariviere

01/06/2021, 10:21 PM
Thanks @josh!