-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
prefect-aws 0.5.3 cannot import 'Integration' from 'prefect.client.schemas.objects' #16188
Comments
hi @jggatter - thanks for the issue! what appears to be happening here is that since you've selected so should be able to update your base image to just » docker run --rm -it prefecthq/prefect:3.0-python3.12 /bin/bash
root@98896b712d36:/opt/prefect# prefect version
Version: 3.0.11
API version: 0.8.4
Python version: 3.12.7
Git commit: a17ccfcf
Built: Thu, Oct 24, 2024 5:36 PM
OS/Arch: linux/aarch64
Profile: ephemeral
Server type: ephemeral
Pydantic version: 2.9.2
Server:
Database: sqlite
SQLite version: 3.40.1
root@98896b712d36:/opt/prefect# python -c "from prefect.client.schemas.objects import Integration"
Traceback (most recent call last):
File "<string>", line 1, in <module>
ImportError: cannot import name 'Integration' from 'prefect.client.schemas.objects' rereading your issue, im not yet convinced I have the story perfectly straight, will keep digging in particular, its surprising to me to see
as this combination should work fine. @jggatter can you confirm where these logs came from? I assume the ECS flow run container, but just double checking |
Thanks for the quick reply! Yep, we run containers on ECS Fargate via our push pool. Yeah, I was also confused to see the prefect-aws installation picking up prefect >= 3.1.3. Perhaps our prefect YAML deployment requiring prefect-aws >= 0.3.4 for the code pulling step causes this reinstallation. Even then, I suppose it appears the setup steps continue with the original prefect version and do not use the newly installed prefect? Not sure if there are subprocesses/different Pythons runtimes being used in the deployment steps. In any case I think it's likely just a problem with our setup then. It's better practice for us to keep up with latest docker images or I suppose keep pins in our Prefect YAML files that don't allow for installation of newer, possibly incompatible, versions e.g. prefect-aws 0.5.3. |
thanks for the update! after #16192, it should be harder to get into such a state, so I'll close this for now please let us know if something related comes up! |
Bug summary
A user from my organization reported a crash this morning. It appears that Prefect is unable to pull our code from S3 due to an ImportError.
CloudWatch Logs:
Yesterday, before the prefect-aws 0.5.3 release, things appeared to be working for this developer. Given the ImportError and recent prefect-aws release, I assume that the release has some incompatibilities with the latest Prefect version, 3.1.5.
Dockerfile:
Requirements.txt
Our stop gap solution that seems to have worked was:
prefect == 3.1.4
andprefect-aws == 0.5.2
Unfortunately I do not have time to confirm my suspicions by looking through the Prefect codebase or trying to reproduce with different versions. Please let me know whether any further information is needed.
Version info
Additional context
Was using the prefecthq/prefect3.0-python3.12 image
ECS Fargate runtime.
The text was updated successfully, but these errors were encountered: