Hi all, I'm looking for some help with the follow...
# prefect-community
Hi all, I'm looking for some help with the following error: Failed to load and execute flow run: ModuleNotFoundError("No module named 'pyodbc'") We are running an Ec2 instance with the Prefect Docker Agent. --How do we install the Python modules? Is it needed on the Ec2 instance, (which we did) or is there a way to load it into the container? Thanks for your assistance and support.
Yes you would need it in the execution environment, so it needs to be in the container. This syntax will work as long as you use a base prefect image
connecting to a SQL Server DB from a Docker container can be challenging - I'd definitely recommend not starting your Dockerfile from scratch but googling a bit about how others tackled this since you need to ensure you have the DB driver and everything set up - not trivial (just a heads up to avoid your negative engineering here)
Thanks Kevin, and Anna. I really appreciate your help.