Hi all, I’m trying to run Pytest for a Prefect project in a docker container. Pytest works locally (using Poetry to create virtual environment) but I’m running into a ModuleNotFoundError for prefect.logging when executing pytest on the docker image. My Prefect version is 2.7.6. Any idea’s why this would happen?
Jelle Vegter
01/06/2023, 3:49 PM
I use Azure as storage btw
Jelle Vegter
01/06/2023, 4:14 PM
Also importing as from prefect.logging.loggers import disable_run_logger fails for the same reason: ModuleNotFoundError: No module named ‘prefect.logging’
Jelle Vegter
01/06/2023, 5:20 PM
This is from within the container
Jelle Vegter
01/06/2023, 5:20 PM
pytest throws ModuleNotFoundError: No module named ‘prefect.logging’ but python recognises the package
c
Christopher Boyd
01/09/2023, 2:56 PM
What is the path for prefect.logging - it could be either a) that it’s not installed into the docker container you are running, or if it is, it’s not in the same path