Joe D

09/05/2023, 5:43 PM
Hi all - I'm trying to set up a prefect2 agent following this tutorial My flows use prefect-aws for infrastructure so I'm getting the following error when I launch my flow - I think because prefect-aws is not installed on my instance?
KeyError: "No class found for dispatch key 'ecs-task' in registry for type 'Block'."
If I run
pip3 install prefect-aws
on my instance I get this dependency conflict:
Copy code
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
aiobotocore 2.5.4 requires botocore<1.31.18,>=1.31.17, but you have botocore 1.31.40 which is incompatible.
And when I launch my flow I get the same KeyError along with:
Copy code
Warning!  Failed to load collection 'prefect_aws': AttributeError: module 'lib' has no attribute 'OpenSSL_add_all_algorithms'
17:32:19.694 | ERROR   | prefect.agent - Failed to get infrastructure for flow run '96a4ce05-7431-4062-bb2b-8c039d5d77e0'.
Are there versions of prefect2 / prefect-aws I can use to get this to work? Am I missing something obvious / should I rethink my execution layer?